At a guess,
You may also get a function sequence error if you attempt another SQLExecute call before SQLMoreResults() has returned SQL_NO_DATA_FOUND.
.. may be the answer you seek. That's from this page which I found using Google.
Alex / talexb / Toronto
"Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds