php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #9196 Cannot create ADO objects with MDAC 2.6
Submitted: 2001-02-09 13:45 UTC Modified: 2001-02-10 12:55 UTC
From: peter dot johnson at unified dot co dot uk Assigned:
Status: Closed Package: COM related
PHP Version: 4.0.4pl1 OS: Win2K Winnt4
Private report: No CVE-ID: None
 [2001-02-09 13:45 UTC] peter dot johnson at unified dot co dot uk
The code snippet below fails on the line which sets the Active Connection of the Command Object.  It works OK with MDAC 2.5 SP1, but not MDAC 2.6 - weird...

<?
	require "adovbs.php";
	$conGFA = new COM("ADODB.Connection") or die("Unable to instantiate GFA DB Connection");

	$conGFA -> ConnectionString = "Provider=SQLOLEDB;OLE DB Services=0;Persist Security Info=False;User ID=UserID;Password=Password;Initial Catalog=gfa;Data Source=DBSERVER;";
	$conGFA -> Open;

	$cmdGFA = new COM("ADODB.Command") or die("Unable to instantiate GFA DB Command Object");

	$cmdGFA -> ActiveConnection = $conGFA -> ConnectionString;
?>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-02-10 12:55 UTC] peter dot johnson at unified dot co dot uk
I've managed to work out what was wrong - it seems that if I am using the ZendOptimiser I get problems wth COM, otherwise it works OK.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 13:01:28 2024 UTC