Php/Mysql nested query using 2 dbs
Posted: Fri Sep 15, 2006 8:15 am
I have this line here:
"SELECT alias FROM $grouptable WHERE id IN (SELECT aliasid FROM $grouproletable WHERE roleid ='$id')";
I wish to move the groups into a seperate db to the roles. This means $grouptable and $grouproletable will be in seperate databases. My question is this: is it possible to use the simple and elegant solution that is the nested query across 2 tables that are in serperate dbs. I am totally lost here
"SELECT alias FROM $grouptable WHERE id IN (SELECT aliasid FROM $grouproletable WHERE roleid ='$id')";
I wish to move the groups into a seperate db to the roles. This means $grouptable and $grouproletable will be in seperate databases. My question is this: is it possible to use the simple and elegant solution that is the nested query across 2 tables that are in serperate dbs. I am totally lost here