Welcome Guest, Not a member yet? Register   Sign In
How to resolv mutil database connect which is diffenet db type?
#3

[eluser]Pascal Kriete[/eluser]
By passing in the TRUE you're telling CI to return the database object. $this->db will still reference the old version.

Code:
$msdb = $this->load->database($config,TRUE);
$query = $msdb->get(’baseinfo’);
if ($query->num_rows() > 0)
    {
    foreach ($query->result() as $row)
    {
        echo $row->password;
    }
}
Information on connecting to several databases is at the bottom of this page.

And just out of curiosity, why do you have two vastly different databases?


Messages In This Thread
How to resolv mutil database connect which is diffenet db type? - by El Forum - 05-08-2008, 10:17 AM



Theme © iAndrew 2016 - Forum software by © MyBB