Welcome Guest, Not a member yet? Register   Sign In
Conencting to multiple databases at same time, without knowing second database details to start with
#1

[eluser]DavidHopkins[/eluser]
Hello all, im new to codeigniter and am really enjoying it.

However i have a slight issue with database connections, well two databases connections to be honest.

My application i am trying to build has a default database that has all the users details etc. THis is used to log in and carry out other basic funcitons. I have set this database up using the config inside database.php and can use it by just calling $this->db->

My problem comes however when i try to add a second database, which is unique to each person who logs in so i dont know their details until they have logged in.

I wish to set this database up in such a way i can access it like $this->db2->

Can anyone please help me with this ?

SOme example code would be great !

THanks

David Hopkins


Messages In This Thread
Conencting to multiple databases at same time, without knowing second database details to start with - by El Forum - 01-30-2012, 01:59 PM



Theme © iAndrew 2016 - Forum software by © MyBB