[eluser]Swedie[/eluser]
The fix was setting up separate mysql accounts for each database. I know I know... I should've done this from start.
It probably have this limit on multi use of the root account. Not sure same limit would apply on a non root account. Haven't tried.
On my local machine I have 2 (out of 5) multiple uses of root in the same CI application.
But on the live production server, I had 3 DB instances with the same root login.
So to repeat the error on your end, try having 3 different DB instanstances all with the same root login and make calls to them one after another. See if each query works as expected and tries to read from the correct DB.
I also believe now this probably isn't a CI problem in itself, but a fundamental limit to how PHP / MySQL works. A good limit actually, but the debugging of this isn't easy when there is no lead to what's causing it really. Maybe an error stating "no multi use of root login" would be fair. I'm sure some here would say that it's common knowledge though.