Staggan Posted March 3, 2015 Share Posted March 3, 2015 Hello I am looking for information on allowing multiple instances of our application to access the same database... Currently we have each instance(generally a geographic region) of our application having its own database but this is proving problematic to manage... but if a user decides to install the application for another region all their user data is non existent in that region, so a new account must be created.. Ideally we would like to have a single user database for ALL instances (regions).... Is there any specific I need to do or consider to allow this? Thanks Quote Link to comment Share on other sites More sharing options...
joel24 Posted March 3, 2015 Share Posted March 3, 2015 I would just use a single database and set it up in a relational way to have a region table and link each user to that table, why do you have multiple instances? are the applications vastly different between regions? Quote Link to comment Share on other sites More sharing options...
Staggan Posted March 4, 2015 Author Share Posted March 4, 2015 Originally It is was to do with server loading and regional latency, but we have introduced new systems to mitigate this to the point now where managing multiple user databases has become time consuming and problematic... My question is more about the implications of multiple connections to a MySQL database access the same tables at the same time... So, if I have one user table in a database and multiple connections to that database that act on that user table, what are the implications? Quote Link to comment Share on other sites More sharing options...
joel24 Posted March 5, 2015 Share Posted March 5, 2015 as long as they're not modifying the same field, it's fine... I'm not sure what kind of system you're running though the above will only be an issue if there are multiple people using hte same account or updating the same user row, then you can put a lock on the row though it's starting to seem like a convoluted solution to a simple problem. multiple connections to the table doing whatever is fine, if one tries to edit the same row whilst another is editing, the second edit's attempt will overwrite the first. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.