[eluser]AlexandrosG[/eluser]
I have this piece of code:
Code:
$sql = "UPDATE $this->table SET password = '$profile[password]', name = '$profile[name]', email = '$profile[email]', info = '$profile[info]' WHERE userid = '$profile[userid]'";
$this->lisdb->query($sql);
inside a model.
When i echo "$this->table" , i get "smith1_users".
When i echo "$this->lisdb->database" i get "mylis0_lisdb".
BUT when i try to execute the above code i get:
Code:
Error Number: 1146
Table 'mylis0_lispdb.smith1_users' doesn't exist
What is going wrong here??? Why CI tries to connect to wrong database? :-(
Note: The model's method that the code belongs connects to 3 databases manually using a separate model property to store each database object. The above piece of code is being calld from inside an iframe.