Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ODBC error: Invalid cursor state

Status
Not open for further replies.

Stephan888

Programmer
Aug 24, 2003
4
US
We're using Crystal Reports 8.5 (and SQL Server 2000 for the back-end) and are getting the following error message with one of our reports:

"ODBC error:[Microsoft][ODBC SQL Server Driver]Invalid cursor state"

All the other reports are working fine. The report in issue was working fine until we modified the stored procedure, but the stored procedure runs okay in SQL Server itself.

I've been spinning my wheels for 2 days on this one. I found one other post here on Tek-Tips from skuhlman who experienced a similiar error, but wasn't sure if he ever found a resolution.

skuhlman or anyone else who has an idea of how to solve this, I'd appreciate any input.

Thanks,

--Stephan
 
What connectivity are you using?

Is the last thing in the SP a select statement?

Generally cursors should be avoided, and often times can be.

Since the problem is related to the new SQL, and you didn't share it, it's difficult to guess.

Make sure that you use the CR supplied ODBC driver, or use OLE DB (this fixes a known issue with that error under CR 9).

-k
 
Sometimes the parameters in your report cause this error. See if you cannot put the parameters in your stored procedure and pass them to the report.

[flowerface]
crystalguru
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top