BoazY's avatar
BoazY
Regular Visitor
9 years ago
Status:
Needs Votes

Load Data Dynamically - (Generally & For Priority)

I work with the program "Priority". Each customer has a database. In each database, there are a few companies belonging to one customer. Priority is structured such that each company has the same exact tables. There is a specific table that lists for each customer's company names. I would like to load data dynamically such that I can enter in a variable the name of the company, for example the custome's name is CDSE#, custome's name is AAA, and if its a query in SQL, the row labeled "FROM" would be FROM CDSE#AAA.dbo.DOCUMENTS--this is in the case that the variable WWW would look like FROM CDSE#WWW.dbo.DOCUMENTS. Therefore for each table, such as "DOCUMENTS", i need to change CONNECTION such that the variable WWW would receive now the name of the next company after one LOOP of uploading, so on and so forth, until the entire DOCUMENT table is filled for all the companies belonging to one customer, and in each LOOP, it would add a key of the company to the table.

Recent ideas