From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Two reports from one Sequence

I have a test sequence which generates such a long xml report, we can't import the data into our database. I've been told this is because of SQL limitations. Don't know more than that.

My idea was to generate two or more reports for each UUT run. The logical way to do this is to split the sequence into two subsequences, then call each of them with a Main controlling sequence.

This of course still only generates one report. Would it be easy to modify the process model so that the call to the subsequences generate a separate report for each? Any better way to do this?

Dave
0 Kudos
Message 1 of 10
(4,156 Views)
Hey Dave,
 
Is there any reason that you're not using TestStand's intergrating Database logging as opposed to creating the XML and using that to import to the database.  It seems as if this may be easier.  Just another avenue to look at.
 
Adam
0 Kudos
Message 2 of 10
(4,128 Views)
Hey Dave,

The short answer to your question is yes it would be possible to split up the XML reports, but it would involve changing a lot of the reporting code in the process model.  Just by the very nature of XML documents it will be difficult because XML documents are well formed documents meaning that each of your reports would have to have a header and footer.  I imagine this might make it more difficult to log it into the database.

Adam brings up a really good point.  Have you looked at the built in database logging features of TestStand?  This might be an easier way to accomplish what you want to do.


Pat P.
Software Engineer
National Instruments
0 Kudos
Message 3 of 10
(4,122 Views)
Our reasoning for not connecting to a centralized database was test speed.  It was a few years ago, but I recollect that we tried it and the test was significantly slower using the database functions.  Also, the test is less dependant on the network.  i.e. there can be network problems  but the test will continue to run at full speed since it stores the xml files locally.  Our server can then retrieve the reports later for inporting into the database.
 
Yes, I expected that the process model would have to be modified.  I was hoping someone has done something like this already.Smiley Happy
0 Kudos
Message 4 of 10
(4,117 Views)

Cabman,

I'm doing the same thing. It's especially useful to export XML files from our CM's. I don't have a solution but I'm wondering how large your XML files are and whether it's something I will have to address. What database are you using?

0 Kudos
Message 5 of 10
(4,112 Views)
do you use "on-the-fly datalogging" when you test the DB connectivity?

or did you write the DB after finishing the test sequence / viewing the xml report?

regards
timo
0 Kudos
Message 6 of 10
(4,102 Views)
Dennis,
 
From our database programmer:
 
SQL Server 2000.  The sql error we get is an 'exceeding columns1024' using the sqlxmlbulkload command.  This relates to 512 tests in the report.  Note that each item in a multiple numeric entry relates to 2 columns which is what kills me because I use multiple numerics a lot.
 
 
Timo,
 
I believe it was writing to the DB after finishing the sequence, where it would pause between tests.
0 Kudos
Message 7 of 10
(4,087 Views)

Cabman,

Thanks for the info. I'm using the same version of SQL Server but the difference is in the number of columns it seems. Our current schema is actually based on something we developed when we were still using TestStand 1 and before the multiple numeric limit. I have requested the database to be changed to handle this and yes I have been waiting a long time. My test results database is part of a large corporate database that also handles ordering, shipping, defect tracking, etc. My add-ons are usually pushed to the bottom of the list but I'll keep in mind that there might be some limitations.

Dennis

0 Kudos
Message 8 of 10
(4,084 Views)
I believe the easiest method for getting your results into a database is to use the standard Database Logging functionality.  However, if you are unable to get that working than it may be possible to split your XML files into different reports.  I am assuming that you you are simply taking the raw XML data and pushing into the Database in some way.  The XML is generated in a fairly simple way.  The ResultList for the MainSequence call is accessed as a PropertyObject.  The ResultList contains all the results of the MainSequence and all subsequences as well.  To simplify the generation of XML you could split the ResultList items into two seperate PropertyObjects.  With each ResultList container as a PropertyObject, you can use the GetXML() method.  GetXML() simply returns a string that is the XML representation of a PropertyObject.  This is the same method that is used to create the XML report document in the standard Process Models.

The difficult part, of course, is to split up the ResultList.  Depending upon the structure of your test sequences, you need to find some place that you would like to split the results.  The easiest method may be to split the MainSequence ResultList into two parts.  That way, you would not have to worry too much about handling subsequence results.

Let me know if you have further questions.

Tyler Tigue
Applications Engineer
National Instruments

Message Edited by Tyler T. on 04-24-2006 11:14 AM

0 Kudos
Message 9 of 10
(4,048 Views)
Thanks for the tips Tyler.  I hope to try this later this week.
0 Kudos
Message 10 of 10
(4,027 Views)