There is a sample of how to do this on the PHP manual page on COM. For those
lazy folks, here's some code that I have already used.
+ + + + +
$dbConn = new COM("ADODB.Connection") or die ("ouch!");
$dbConn->Open("Provider=SQLOLEDB; Data Source=server1; Initial Catalog=Pubs;
User ID=dbo; Password=");
$recordset = $dbConn->Execute($sql);
while (! $recordset->EOF) {
// *** here's the only real problem with using the ADO object
// you *have* to use two lines of code to extract the value.
$field = $recordset->Fields("fieldname");
print $field->value;
$recordset->MoveNext();
}
$recordset->Close();
$dbConn->Close();
+ + + + + +
hth,
-james.
To: [EMAIL PROTECTED]
Date: Thu, 12 Jul 2001 11:57:23 +0800
From: gary
Subject: Re: [PHP-WIN] large number of data in MSSQL
Hi Dario, Thank you. I would like to know how to use ADO in MSSQL 7.0. Can
you
tell me, please?
Gary
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]