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.
 
Top