用户
 找回密码
 入住 CI 中国社区
搜索
查看: 3512|回复: 0
收起左侧

[数据库] 数据库连接提示could not translate host name "user=" to address

[复制链接]
发表于 2017-11-8 15:40:39 | 显示全部楼层 |阅读模式
我这边现在又2个数据库,一个中心库用来登录验证,一个是用户库。但是用户库是登录后根据账号的编号来加载不同的用户库。用户登录后,加载了自己的公司库,在控制器基础信息A中,就可以查询出自己库内的个人以及公司信息。控制器B的构造函数内加载了用户数据库:
function __construct()
{
    parent::__construct();
    $this->load->library('lib_userdb');
    $this->load->library('lib_common');
    $this->userdb = $this->lib_userdb->load_customer_database();
}
在这个控制器下边的一个文件上传方法内,提示无法连接到数据库。错误信息如下:ERROR - 2017-11-08 15:27:27 --> Severity: Warning --> pg_pconnect(): Unable to connect to PostgreSQL server: could not translate host name "user=" to address: Unknown host D:\www\system\database\drivers\postgre\postgre_driver.php 153
ERROR - 2017-11-08 15:27:27 --> Unable to connect to the database
请大神帮忙看下如何解决这个问题呢?谢谢

本版积分规则