try iterating through the DBEngine.Errors collection. Usually, there will be
more error info in there; you are only seeing the top-most message in the
For mIndex = 1 to DBEngine.Errors.Count
This will hopefully help. You can comment this stuff out after it works, and
if you have problems later, just un-comment the lines to revive the extra
Quote:>I am using a stored procedure to copy about 24000 records from one table to
>another. I am invoking the sp from a vb5 program. Code snip follows:
> Set workspace1 = DBEngine.CreateWorkspace("odbc", "uid", "pwd",
> Set dbSQL = workspace1.OpenDatabase("ODBC", dbDriverPrompt)
> Set qdRevenue = dbSQL.Connection.CreateQueryDef("", "Exec
> qdRevenue.Execute dbRunAsync
>Problem is, it executes for a couple of minutes, then dies. If I check
>qdRevenue.StillExecuting after it dies, I get 'Operation Cancelled'. If I
>check it before it dies, it correctly returns True.
>1) Does anyone recognize this problem?
>2) When you get an "Operation Cancelled", how do you diagnose the real
>cause of the problem?
>PS: The log is 75 mb - and not anywhere near full. If I run the sp from
>SQL Enterprise Manager, it runs a-ok.