>>>I'm testing CursorAdaptors for my MySQL database using an ODBC connection. For some reason, everything works fine until the returned cursor is > 99 records - then I get no cursor at all; I also get no errors and the CursorFill() result is .T. BTW, the ConnectionTimeOut is 600.
>>>
>>>This occurs whether the query is run on the server or a workstation and I've verified the query in the MySQL Query Browser. These are local cursors, so CURSORSETPROP()'s FetchSize and MaxRecords don't apply.
>>>
>>>Anyone have an idea what might be causing this?
>>>
>>>Thanks,
>>>Ken
>>
>>I think the problem is in your cursor's query SQL and base table in mySQL. It looks like you have a query that would work right with the first 99.
>>
>>I use CA against SQL server and I don't have any problems loading even hundreds of thousands records. I would never expect mySQL would have a problem with that.
>>
>>PS: I don't understand what you mean by "These are local cursors, so CURSORSETPROP()'s FetchSize and MaxRecords don't apply.". If they are local cursors then how come you are querying them via mySQL ODBC driver?
>>
>>Cetin
>
>1. VFP's CURSORSETPROP()'s help says, "This property is primarily used for remote views; setting it has no effect on local views." Further, when I try to set them, I get an error: "Property is invalid for table cursors." I think my use of "local" was confusing.
>
>2. When you say my problem is "in the cursor's query SQL and base table", what do you have in mind? I save the complete query to a file just before executing, then I paste that directly into the MySQL Query Browser and it works just fine?
>
>Thanks,
>Ken
1) CursorAdapter have FetchSize and MaxRecords properties and it is not a local cursor. That is why I didn't understand.
2) What I thought was something like a query that doesn't expose the problem in first N records (and those N records should be based on some where expression - another one causes it to surface).
"When it doesn't populate at all there is something wrong in SQL" is one that I observed with CA. There may be other reasons of course. Did you check with aerror()? I would also step in BeforeCursorFill and AfterCursorFill events.
Also try that query that yiu use in query browser with:
DO HOME() + "DataExplorer.app"
And finally maybe you paste the query here so there is a possibility that we can spot something (you use text...endtext already,right?)
Cetin