Insert Data from a Table in another DataBase - Sql Server -



Insert Data from a Table in another DataBase - Sql Server -

insert customersnew (customername, country) select customername, country customersold status='n';

in above case can insert client info table "customersnew" exist in table customersold.

these 2 tables in same database

how perform same operation if these tables resides in 2 databases.

ex

table "customersnew" in db_new.

table "customersold" in db_old.

these 2 databases in 2 different locations.... how access security..(data bases have passwords......)

insert db_new.dbo.customersnew(customername, country) select customername, country db_old.dbo.customersold status='n'

sql-server sql-server-2008

Comments

Popular posts from this blog

php - How to pass multiple values from url -

php - Laravel not returning controller -

c# - Confused on how to specify a Platform and Version while using ChromeOptions for RemoteWebDriver with Selenium donNet since recent updates -