Quantcast
Channel: FiveTech Software tech support forums
Viewing all articles
Browse latest Browse all 26222

Error from ADO

$
0
0
[b:3ir01yui]CursorLocation [/b:3ir01yui]1 [i:3ir01yui]adUseNone[/i:3ir01yui] (Obsolete and does not work) 2. [i:3ir01yui]adUseServer[/i:3ir01yui] (Can not navigate and is not useful for us) [b:3ir01yui]3. adUseClient : This is the only choice we have[/b:3ir01yui] LockType: 1. [i:3ir01yui]adLockUnspecified[/i:3ir01yui] (not to be used for new recordsets) 2. adLockReadOnly : This is not what you want when you want to make changes. (Note: This is useful when you read data not to be modified) 3. [i:3ir01yui]adLockPessimistic[/i:3ir01yui]: We need to lock each record for modification. Rarely anybody uses it. 5. adLockBatchOptimistic: Useful. But for more advanced users. [b:3ir01yui]4. adLockOptimistic: This is the only choice we have[/b:3ir01yui] CursorType: 0. [i:3ir01yui]adOpenForwardOnly[/i:3ir01yui] : Works only with adUseServer and in anycase this is not what we want 1. [i:3ir01yui]adOpenKeyset[/i:3ir01yui]: Whether we like or not this work only with adUseServer 2. [i:3ir01yui]adOpenDynamic[/i:3ir01yui]: This also does not work with adUseClient [b:3ir01yui]3. adOpenStatic: This is the only choice left to us.[/b:3ir01yui] [color=#FF0000:3ir01yui][b:3ir01yui]Even if you try to use adOpenKeySet or adOpenDynamc the ADO system will open the recordset with adUseStatic only.[/b:3ir01yui][/color:3ir01yui] Test: Try opening a recordset with cursor types 1 or 2. After opening the recordset, try ? oRs:CursorType. The result always is 3 (adOpenStatic) We are left with these choices only and we have no other choices: [b:3ir01yui]CursorLocation : adUseClient (3)[/b:3ir01yui] [b:3ir01yui]LockType: adLockOptimistic (4)[/b:3ir01yui] // If you know how to handle, adLockBatchOptimistic can also be used. [b:3ir01yui]CursorType: adOpenStatic.[/b:3ir01yui] (3) Now this also means that trying other values, like adOpenKeyset or adOpenDynamic, has no meaning and is a sheer waste of time.

Viewing all articles
Browse latest Browse all 26222

Trending Articles