Dynamic Cursor in MS-Access

wxdqz

New Member
Hi all. I'm trying to figure out how to open a connection with a dynamic cursor using either the embedded ODBC calls or ADO and am having no luck. Maybe I'm missing something obvious, I don't know.

Firstly, the internal odbc_ functions don't seem to support it according to the docs on php.net, right? I suppose I could execute my query, and run a for loop to dump the contents into an array using odbc_fetch_into, but doesn't that sound inefficient?

I also considered just using ADO, but in order to use ADO with a dynamic cursor it requires the format:

// Open the DB
$conn = new COM( "ADODB.Connection" );
$rs = new COM( "ADODB.Recordset" );

// Set cursortype
$rs->CursorType = adOpenStatic;
$rs->CursorLocation = adUseClient

// Now open the darn thing
$conn->Open( "DBQ=mydb.mdb;Driver={Microsoft Access Driver (*.mdb)};" );
$rs->Open( "SELECT * FROM myTable, $conn , 2, 3 )

Needless to say, as many have pointed out in this forum, the last line will always fail. Does this mean I can't use a dynamic cursor at all? Help!

(And thanks in advance.)
 
Back
Top