Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/codeigniter/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 无法将Codeigniter 3.1.5与Firebird 1.5连接-错误无法连接,因为目标机器主动拒绝连接_Php_Codeigniter_Pdo_Firebird1.5 - Fatal编程技术网

Php 无法将Codeigniter 3.1.5与Firebird 1.5连接-错误无法连接,因为目标机器主动拒绝连接

Php 无法将Codeigniter 3.1.5与Firebird 1.5连接-错误无法连接,因为目标机器主动拒绝连接,php,codeigniter,pdo,firebird1.5,Php,Codeigniter,Pdo,Firebird1.5,我是Codeigniter 3.1.5的新手,在连接到Firebird 1.5时遇到问题(我知道它是旧版本,但我需要这个)。我使用的是WAMP 3.0.6和PHP5.6.25。我尝试使用ibase驱动程序,但没有成功。现在我正在尝试使用PDO驱动程序,但出现了“数据库错误”:SQLSTATE[HY000][2002]无法建立连接,因为目标计算机主动拒绝了它。 在Apache2.4.23中,我启用了PDO和PDO_sqlite扩展 这是我的代码: $db['firebird'] = array(

我是Codeigniter 3.1.5的新手,在连接到Firebird 1.5时遇到问题(我知道它是旧版本,但我需要这个)。我使用的是WAMP 3.0.6和PHP5.6.25。我尝试使用ibase驱动程序,但没有成功。现在我正在尝试使用PDO驱动程序,但出现了“数据库错误”:SQLSTATE[HY000][2002]无法建立连接,因为目标计算机主动拒绝了它。 在Apache2.4.23中,我启用了PDO和PDO_sqlite扩展

这是我的代码:

 $db['firebird'] = array( 
    'dsn' =>'firebird:dbname=D:\firebird\TEST.;charset=utf8',
    'hostname' => 'localhost',
    'username' => 'sysdba', 
    'password' => 'masterkey', 
    'database' => 'D:\firebird\TEST.FDB',
    'dbdriver' => 'pdo', 
    'dbprefix' => '', 
    'pconnect' => FALSE, 
    'db_debug' => (ENVIRONMENT !== 'production'),
    'cache_on' => FALSE, 
    'cachedir' => '', 
    'char_set' => 'ANSI',
    'dbcollat' => 'NONE',
    'swap_pre' => '',
    'encrypt' => FALSE,
    'compress' => FALSE,
    'stricton' => FALSE, 
    'failover' => array(),
    'save_queries' => TRUE ); 

问题是我的WAMP是64位,Firebird是32位。更改为32位WAMP后,它就可以工作了。

该错误不是Firebird错误(似乎是MySQL错误!)。请显示代码和完整的错误信息。编辑您的问题,不要使用注释发布codeCorrection,这是windows套接字错误,但我想不起来Firebird传播了该错误。请不要将已解决的问题附加到标题中。相反,把你的答案标记为“接受”。这样其他人就会知道问题已经解决了。我想安装64位Firebird客户端就足够了