Cancel

G

George Hester

An SQL function I have executes a SQL statement and returns a recordset. But sometimes the result of the SQL query will be empty. Therefore I am writing a blank table and the result call it ExecuteSQL.Clone is not a recordset. And the error occurs in the Function "BOF or EOF has occurred..." Is thre a way I can cancel the resordset that the function returns and have it just return nothing? Like:

I thought maybe the Cancel method but I am not using a ODBC Workspace I don't think anyway.
 
F

Frits van Soldt

An SQL function I have executes a SQL statement and returns a recordset.
But sometimes the result of the SQL query will be empty. Therefore I am
writing a blank table and the result call it ExecuteSQL.Clone is not a
recordset. And the error occurs in the Function "BOF or EOF has
occurred..." Is thre a way I can cancel the resordset that the function
returns and have it just return nothing? Like:

I thought maybe the Cancel method but I am not using a ODBC Workspace I
don't think anyway.

Just test for EOF on the recordset.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top