It's not often I see an error that I have simply never seen before. Here's one that some of you may recognize. It happened on a query using SELECT * against a fairly limited table on an MSSQL 2005 database. There wasn't anything unusual about the query (except for the bad form of using the asterisk). Here's the error that was thrown:
After scratching my head and consulting my crystal ball I went looking at the "advanced" properties for the data source. What I found was that the "Select Method" for the DB which is usually set to "direct" had been set to "cursor". Setting it back to "direct" cleared up the error. Now, as I understand it, a "cursor" select method (available for MS SQL and Sybase) would allow a developer to work his way through a data set (a cursor) on the DB server - rather than directly selecting all the records into the web server memory. At least that's what I gather.
The problem is that I cannot find any examples of how this is done. One blog post said, "using the cursor select method should only be done by advanced developers". Of course, now I feel like a novice because frankly, I don't know how to do it either. So first, if you see the error above there is an easy fix. Switch from cursor back to the direct select method. Secondly, are there any savvy Muse readers out there with a sample of how a cursor select method might be used? I certainly have enough complex DB code out there to make learning a new technique worth my while :)