Oh, I see now - that's the same setting you're changing to cause one site or the other to work.

That is strange that changing one database would affect the other site.
What do you have for cookie path under "Cookies and HTTP Header Options"? If you're using the same domain name but a different path for your test site, you might need to change that to someting other than '/'.