I would like to consolidate their generated sql database ".bak" in my main server but without overwritting or replacing my existing database. it's like just inserting data to my main server.
I am assuming that "Client Server" and "Main Server" are two completely separate instances.
You want to get data from "Client Server" into "Main Server".
You have a backup of "Client Server" (CS.bak)
If you restore CS.bak over "Main Server" you will overwrite "Main Server", this is not a good thing.
My suggestions is restore CS.bak to a database with a name other than "Main Server (you "stage" the data in a separate database) to the same instance that contains "Main Server"
You then write insert/merge statements from "stage" to "Main Server" to consolidate the data.
You can use three part naming to achieve this, for example you can run select statements against tables in other databases on the same instance (permissions allowing) by
One think, any suggestion for me. B'coz right now i developed system software for my company and it will deploy for 500 gasoline station. Any idea what should i do about their DB.
Do i need to install MS SQL Server each station or any possible way to lessen my issue about consolidating their data?
What do you mean by internet connectivity? they will connect to our server which is my "Main Server" so that no issue of restoring and duplicating? Am i right of what you mean?
So this software tou wrote for them does not sound like a web application but a client side app.
2 options
Local database, where would this be installed? At the gas station? You would need some way of identifying the store by storing storeId to differentiate one stores data from the other when processing backup file. This approach of backup and restore sounds very fragile and too complicated. What version of sql server, how will you manage licensing etc? What backup plans do you have?
Centralized database at main office or on the cloud.
This would be the better option but it depends on how good internet they have for the app to connect to database centralized.
Can you give me example of what your're trying to say having internet then pointing the connection string to the main server? Sorry for late reply i'm been busy this past few days its so hard to understand this kind of scenario. huhuhu
This is what I mean. AS the name implies, it is the settings that allow your application to connect to the SQL server. So you have 500 gas stations and one sql server located at the main office. In order for these 500 office locations' application, if installed at each gas station location, will require connection string, or connection detail, shown below, in order to read and write data. for this data stream to travel to the central office, you need some sort of connection, be it internet, dial up, satellite etc.