Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi There,
Recently I am working on building a report which requires data from different sources. Data is stored in different SQL Server and different Database. I am wondering how to load data located in 2 database by editing script.
Any response will be appreciated. Thank you so much!
Gloria
Simply connect to the different databases in turn:
oledb connect to .... database1;
Table1:
sql select ... from ... ;
disconnect;
oledb connect to .... database2;
Table2:
sql select ... from ... ;
You can use the Connect... button on the Data tab in the script editor to define the connection. After creating the connection you can use the Select... button to create a statement to load data from the database you created the connection for.
Thank you so much for your reply. I have loaded data successfully!