NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Report database is reaching 2GB limit

Hello,

we have a long term test with 6 UUTs and want to log the results into a database. We know from tests in the past that the database size is limited to 2GB. So at the moment we have to interrupt the test for database changing and start it again which is not satisfying.

Is there a possibility to have seperate databases for each test socket ? So that we could increase the testing time. Also analysing would be easier.
Or is it possible that TestStand automaticly creates volumes of the database if the limit is reached so that we do not have to break at all ?

We are using TestStand 3.1 with parallel model.

Thanks for help

Thomas
0 Kudos
Message 1 of 4
(3,160 Views)
What database engine are you using? From the MySQL reference manual, you should be able to get up to 2TB or more on a windows machine. You could also consider moving to MS SQL Server. Microsoft states it's maximum database size 1,048,516 terabytes.

Rob
0 Kudos
Message 2 of 4
(3,153 Views)
Hello Rob,

i am using the access. I attached my schema-ini and a empty database.

Thomas
0 Kudos
Message 3 of 4
(3,148 Views)
Thomas -
Currently the database logging feature stores the active session to the database in a variable attached to the execution. The sharing of the session is based on the schema name. So if we can change the schema name and the connection string prior to logging the data, the alternate database should be used.

If you are using post UUR logging (not on the fly) the following with TS 3.1 appears to work. My default connection string is:

    Provider=Microsoft.Jet.OLEDB.4.0;
    Data Source=D:\Perforce\3.5\App\TestStand\Components\NI\Models\TestStandModels\Database\database0.mdb;
    Persist Security Info=False

Change "Parameters.DatabaseOptions" from "pass by ref" to "pass by value" in the "Log to Database" sequence of "Database.seq", so that edits to the database options are not shared with other sockets.

Add a statement step to the top of the sequence to append a socket number at the end of the database name and the schema name.

    StepType, Adapter: Statement,

    Description:

      Parameters.DatabaseOptions.ConnectionString =
      SearchAndReplace(Parameters.DatabaseOptions.ConnectionString,
      "database.mdb", "database" + Str(Parameters.UUT.TestSocketIndex)
      + ".mdb"),
      Parameters.DatabaseOptions.DatabaseSchema.Name +=
      Str(Parameters.UUT.TestSocketIndex)

    Flow Properties:

      Precondition:
      Parameters.UUT.TestSocketIndex > -1



If you are doing on the fly logging, you could do the following, in the sequence "Single Pass -- Test Socket Entry Point" in ParallelModel.seq
1) Add a new Locals.DatabaseOptions variable.
2) Edit the Step: "New UUT for Database Logging" by adding a preexpression as shown below and pass
Locals.DatabaseOptions instead to the call:


    StepType, Adapter: Action, ActiveX/COM

    Description:

      Action, Call ITSDBLog{Locals.DBLogRef}.NewUUT (ThisContext,
      Parameters.TestSocket.UUT, Locals.DatabaseOptions,
      Parameters.TestSocket.StartTime, Parameters.TestSocket.StartDate,
      Parameters.ModelData.StationInfo)

    Flow Properties:

      Precondition:
      !(Locals.DBLogRef == Nothing)

      Pre Expression:
      Locals.DatabaseOptions = Parameters.ModelData.DatabaseOptions,
      Locals.DatabaseOptions.ConnectionString =
      SearchAndReplace(Locals.DatabaseOptions.ConnectionString,
      "database.mdb", "database" + Str(RunState.TestSockets.MyIndex) +
      ".mdb"),
      Locals.DatabaseOptions.DatabaseSchema.Name +=
      Str(RunState.TestSockets.MyIndex)



Make a similar change to the Test UUTs socket entry point.

This should work for you...

Message Edited by Scott Richardson (NI) on 05-03-2005 11:39 AM

Scott Richardson
0 Kudos
Message 4 of 4
(3,152 Views)