Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Insert record in SQL Server 1

Status
Not open for further replies.

kdien

Technical User
Jun 1, 2017
13
CA
Sage 300 2014 (62A)

We need to add a new currency rate type for several databases. We have a script to deploy an SQL script to all of our databases. So I tried to make that SQL script an Insert statement to the CSCRT table.

Running the INSERT statement on a test database did insert the record into the table, but it did not show up on the front-end. Looks like the Accpac Views somehow did not refresh the data from the back-end table.

Is there any way to achieve this so we will not have to log into every single database just to add a new record?
 
How many databases are you talking about? I would imagine that by the time you set up your query, ran it, puzzled over why it isn't showing in Sage, searched the web and then typed out your query you could have updated 10-20 databases manually. [smile]

You could record a macro and then you're down to a few clicks per database by running the macro in each company.

If you really want to know what happens then run dbSpy when you add the rate type in Sage and it will give you the database commands. Keep in mind that the system database will also be updated. That might be where the SQL update would need to target.
 
We have over 40 databases on different servers, and some servers are in remote locations where connection is not great.

Anyway, the system database was the key. There is another CSCRT table in the system DB.

Thanks!
 
Sync the system database, that should do it.
Actually you only need to add the rate type in one company, then sync the system database, that will update all the companies.
You're making it harder than it needs to be.

Sage 300 Certified Consultant
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top