03-02-2009 02:23 PM
Hi,
I am using the TestStand schema and a MySQL database to log my test results.
I have made a copy of UUT_Results & called it UUT_Results_Test and added a number of columns to the new table.
I have a number of variable from my test sequence I want to log to these new columns.
As I can't access the sequence variables in the TestStand schema (without changing the porcess model) I have opted to use a Data Operation in my test seqeunce to log the results to the database.
My problem is when TestStand then goes to log it's reults to the table it creates a new record.
What si the best way to ensure all data is written to the same record.
Maybe there is an easier way that what I am suggesting?
Any advice greatly appreciated.
Regards,
Don1.
Solved! Go to Solution.
03-03-2009 03:42 PM
You can look at this discussion forum, it is similar to your issue. In particular, look at the third post, by nikolair.
I want to reiterate nikolair's recomendation of these two NI Knowledge Base articles:
Logging a New UUT Property to a Database in TestStand
Logging a New Step Property to a Database in TestStand
03-04-2009 09:14 AM
Hi EadieU,
Thanks for the information. I had a read through both documents & I am trying log the Reported Text of a specific test in my sequence to a column of the new UUT_Results_Test table.
Should I be able to do this?
I was trying use the following syntax, Logging.StepResult.extractname.ReportedText
Thanks & Regards,
Don1.
03-05-2009 05:58 PM
Where are you trying to do the logging? In the sequence file or the schema? If in the sequence file, are you using Database step types or are you calling a code module that does the logging?
To further answer your original questions, you can change where the logging is done by selecting or de-selecting the On-the-Fly Reporting option in the Report Options (Configure»Report Options). If On-The-Fly Reporting is selected, the logging is done in the SequenceFilePostResultListEntry engine callback and the logging to the database will occur after every step. If On-The-Fly Reporting is not selected, the logging is done in the Log to Database callback in the process model and the logging to the database will occur at the end of the sequence.
03-06-2009 10:39 AM
Hi,
At the moment I am trying to do the logging in the Schema. (I actually got it working by using StationGlobals which are accessible through the Schema, but now I just figured out that these are StationGlobals for all sequences, which I don't want)
I did try using the database steps types (I am not too familiar SQL), but my results ended up on different rows in the database & I had to remove constraints around foreign keys and ID field, which I would not like to have to do if possible.
Row 1: Results from Database step types
Row 2: Schema Results.
Is there anyway I can call the database step types to update the current record, after the Schema updates the tables?
Thanks for all your help.
PS: I am fairly new to TestStand so my apologies if I am asking stupid questions.
Regards,
Don1.
03-20-2009 06:27 PM - edited 03-20-2009 06:28 PM
I'm looking into this for you. Can you tell me which version of TestStand are you using?
03-22-2009 02:08 PM
Don1 -
Based on what I here you asking is that you want to log multiple values that are related to a sequence that runs. It is unclear if you want to do this for subsequences as well, but I will assume yes. Since the UUT_Result table is designed to have a single row per UUT, this does not seem to be the right place to place this type of data. What you typically want to do is log additional results in a separate table and have its foreign key reference the UUT table primary key. If you want to maintain strict constraints, you basically have to log the UUT result before you log the variables, so using Database steps in your sequence occurs before the UUT record is logged, so that will not work. In TestStand 4.1, NI added a feature called Additional Results that allows any step to add additional result information to the result for a step, and the report generation and database logging features were enhanced to support including this information in reports and in a database. Without these features your task is more difficult to do in TS 4.0 or earlier because you would basically be attempting to duplicate this feature without the additional support that we added to TestStand in 4.1.
03-23-2009 02:16 PM
Hi Scott & EadieU,
Thanks for the replies.
I am using TestStand 4.1.1.
Since posting this original post I have tried another way to log the data. I would appreciate it if you could review my latest post and comment?
http://forums.ni.com/ni/board/message?board.id=330&thread.id=23505
Any feedback greatly appreciated.
Regards,
Don1.
03-24-2009 09:40 AM
Don1 -
Since you are using 4.1.1, what are the reasons that you are not using Additional Results steps at the beginning of sequences to log the local variables that you want, and then use the default schema or a variation on it to log the values to a separate table that points to the UUT-RESULT table? The whole purpose of the Additional Results feature was to do things like this and to use the default reports and database logging features to assist you to capture this information.
03-24-2009 09:52 AM
Hi Scot,
To be honest I am fairly new to TestStand not to familar with how to access "additional results" in the Schema.
Can you point me to any good tutorials on using this function?
Thanks & Regards,
Don1.