Academic Company Events Community Support Solutions Products & Services Contact NI MyNI
This Document is not yet Rated

Why Does the TestStand SQL Schema Return Error -2147217900?



Primary Software:
Primary Software Version: 1.0
Primary Software Fixed Version: N/A
Secondary Software: N/A

Problem:
I've created an SQL Script to automatically create my tables by using a copy of a pre-existing Schema, however when I execute this query within the Database Viewer it returns an error:

Line 1: Incorrect syntax near '('. (-2147217900)

Why does this occur and how can I fix it?

Solution:
The error is in relation to the final statement within the SQL of CONSTRAINT STEP_RESULT_FK FOREIGN KEY (UUT_RESULT) REFERENCES (ID)) where the REFERENCES (ID) isn't identifying the actual table it needs to reference. To solve the issue you will need to edit the script for each table creation section to the following:

CONSTRAINT STEP_RESULT_FK FOREIGN KEY (UUT_RESULT) REFERENCES UUT_RESULT(ID))

Where REFERENCES UUT_RESULT(ID)) now tells the SQL Database which table this is in relation to.

Related Links:
NI TestStand - Test Management Software
SQL Keywords: REFERENCES


Attachments:





Report Date: 05/26/2010
Last Updated: 06/01/2010
Document ID: 59P88KVG

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit