NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Modifying DatabaseSchemas from Testsequence

Is it possible to modify an existing Database Schema dynamically from the Database Options callback ? What would be th exact syntax for doing that ? We want to add additional custom steptypes to the TypesToLog property of the STEP_NUMERICLIMIT Statement.
Or have we to maintain a TestStandDatabaseOptions.ini which includes in its TypesToLog entry for the STEP_NUMERICLIMIT statement all steptypes of all sequences running on a Teststation ?
0 Kudos
Message 1 of 3
(2,883 Views)
Markus -
The "Locals.DatabaseOptions.DatabaseSchema.Statements[3].TypesToLog" property in the SinglePass and TestUUT sequences hold the specific schema data that you are talking about that the database logging uses. If you are trying to access this from other than the entry point sequence you could use "RunState.Root.Locals.DatabaseOptions.DatabaseSchema.Statements[3].TypesToLog".

You can either hardcode the index of 3, or you will have to find the statement by name by looking at their Name subproperty. The syntax of the TypesToLog string value is a comma delimited list of types.

Hope this helps...
Scott Richardson (NI)
Scott Richardson
0 Kudos
Message 2 of 3
(2,881 Views)
Well, my problem was, that I did try to access the DatabaseSchema subproperties during in the database options callback when the DatabaseSchema wasn't initialized yet. Now it works.
0 Kudos
Message 3 of 3
(2,871 Views)