10-17-2018 07:32 AM
Hello,
I have two sequences (Test1 and Test2 ) which have to use diffrent database schemas (Schema1 and Schema2) . I have added LogToDatabase callback to each sequence and configured them as following
In Test1.seq -> Parameters.DatabaseOptions.DatabaseSchema.Name="Schema1"
In Test2.seq -> Parameters.DatabaseOptions.DatabaseSchema.Name="Schema2"
but unfortunately, both of sequences keep using a schema which is marked in the Result Processing.
Have you idea how to resolve the problem?
Thanks
10-18-2018
03:45 PM
- last edited on
10-30-2024
12:41 PM
by
Content Cleaner
According to the help documentation for the Database Options Dialog Box, you may have to include the databases in the ini file or it will default to the default schema. Have you already tried this?
"Database Options Dialog Box": https://www.ni.com/docs/en-US/bundle/teststand-api-reference/page/tsref/database-options-dialog-box....
10-21-2018 12:43 AM
Thank you for the answer, Daniel.
Yes, I have seen TestStandDatabaseSchemas.ini but find there nothing that allows me to switch the default schema. Maybe you can point me what exactly I should change?
10-22-2018 06:10 PM
I dug into some old service requests and found an old forum post that actually state we do not provide the API functions to programmatically change this configuration file. Modifying the schema in the database options by importing/exporting a schema will automatically change the .ini file for you which is the most modification you can do. I'll run this by my colleagues here just to double-check that nothing has changed in the API functionality in the last few years to support this but I believe it's not currently possible. You can post this to our Idea Exchange though. It's a good spot to post ideas that R&D looks at frequently to determine what features to include in future releases of TestStand. Below is a link to the old forum post that I believe is pretty relevant.
https://forums.ni.com/t5/NI-TestStand/Programmatically-load-Database-Schema/td-p/783678
10-24-2018 10:38 AM
Hey airspan,
Also take a look at this example - https://forums.ni.com/t5/Example-Programs/Changing-the-TestStand-Database-During-a-Single-TestStand/...
This lets you switch between to database connections during an execution.
Hope this helps!
Roxy