|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26549 Execute() not functioning in ADO
Submitted: 2003-12-07 09:23 UTC Modified: 2003-12-07 12:24 UTC
From: gerrykwan at netvigator dot com Assigned:
Status: Not a bug Package: COM related
PHP Version: 4.3.4 OS: Win XP SP1
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: gerrykwan at netvigator dot com
New email:
PHP Version: OS:


 [2003-12-07 09:23 UTC] gerrykwan at netvigator dot com
I am using ADO connection to connect an Access database.
I wrote a php file that works perfectly with the version of php4.3.2 cgi version for Win.
Now the application is moved to another system with php4.3.4 as a module of Apache 1.3.28.  The code is exactly the same, but this time the output is sorts of errors.

Reproduce code:
$db = library.MDB;
$realp = realpath("library.MDB");
$dsn = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=$realp"; 

$conn = new COM("ADODB.Connection") or die ("Connection create fail");


$rs = $conn->Execute("SELECT * FROM library ORDER BY code ASC");


Expected result:
The expected result is a table of all records in the database.  The html code for displaying the results has no errors.  As I mentioned, the code works well before.

Actual result:
Warning and errors:
Warning: (null)(): Invoke() failed: ?o?ͨҥ~???p(translation: exceptional occasion happens)?C Source: Microsoft OLE DB Provider for ODBC Drivers Description: [Microsoft][ODBC Microsoft Access Driver] ?ѼƤӤ֡A?w???Ӽ? 1(translation: too few parameters, expected number is 1)?C in c:\program files\apache group\apache\htdocs\book\book_search.php on line "$rs = $conn->Execute("SELECT * FROM library ORDER BY code ASC");"

Fatal error: Call to a member function on a non-object in c:\program files\apache group\apache\htdocs\book\book_search.php on line "$rs->Close();"


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-12-07 12:02 UTC]
Please try using this CVS snapshot:
For Windows:

Try the latest PHP 5 which has a rewritten DOM extension.
(PHP 4 dom is not supported anymore)

 [2003-12-07 12:24 UTC] gerrykwan at netvigator dot com
Thank you for your reply.
I just wonder if only php5 can solve the problem.
Is it sure there is no way to have proper connection using similar method or coding in php4?
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Wed Feb 01 04:03:45 2023 UTC