Welcome Guest, Not a member yet? Register   Sign In
changing databases via $active_group?
#1

(This post was last modified: 06-13-2020, 12:35 PM by richb201.)

I managed to get postgres connected. Here is the connection:

$DB1 = $this->load->database('default', TRUE);
$DB2 = $this->load->database('postgres', TRUE);


My connection to mySQL still works fine without any changes. How do I change the $active_group? I see how to change it in database.php, but I need to change it "on the fly". The image_crud uses $this->ci->db and I'd like it to use $DB2. Is there some way to load a second ci->db structure? 

Also, where did the codeigniter3 documentation go? 
proof that an old dog can learn new tricks
Reply


Messages In This Thread
changing databases via $active_group? - by richb201 - 06-12-2020, 09:46 AM



Theme © iAndrew 2016 - Forum software by © MyBB