. |
Error Message: SQL Query Analyzer "Query Batch Completed with Errors"
When executing a Query in SQL Server Query Analyzer, the bottom title bar of the program will inform you of the status of your SQL script.
- While Running the script (Green Triangle) you will see the status as "Executing Query Batch...".
- A successful Query Batch will have a status of "Completed Query Batch" at the bottom.
- A failed script will read "Query Batch Completed with Errors". This will indicate there is a problem with the Import Mapping created by GoldReg.
Since all standard fields are mapped correctly in GoldReg, the error lies in a Custom Field setup by the user. Custom Field labels can have any numbers or characters listed in the field label for the form, however, certain characters are reserved symbols for coding purposes. The most common character is the apostrophe ( ' ).
Your .sql import script can be fixed in SQL Server Query Analyzer. (We recommend having a database administrator do this).
- Review your Web Form for your Custom Fields and see if there are any with special characters. (We will use Spouse's Name in this example.)
- Open your Script in SQL Server Query Analyzer.
- [CTRL] + F will open the "FIND" dialog box
- Enter the words "Spouse's Name"
- Click "Find Next"
- You will see something like the code below
if not exists(select * from SImpUserFlds WHERE (ImpTypeNum=@iImpTypeNum) and (UserFldNum=20)) insert SImpUserFlds (ImpTypeNum, UserFldNum, UserFldDesc) values (@iImpTypeNum, 20, 'Spouse's_Name_')
if not exists(select * from SImpMap WHERE (ImpTypeNum=@iImpTypeNum) and (UserFldNum=20) and (TblNum=6) and (TblFldName='ANum')) insert SImpMap (ImpTypeNum, UserFldNum, TblNum, TblFldName, RecNum) values (@iImpTypeNum, 20, 6, 'ANum', 1)
- Delete the apostrophe from the label
if not exists(select * from SImpUserFlds WHERE (ImpTypeNum=@iImpTypeNum) and (UserFldNum=20)) insert SImpUserFlds (ImpTypeNum, UserFldNum, UserFldDesc) values (@iImpTypeNum, 20, 'Spouses_Name_')
- [RUN] your query again (Green Triangle) and check the Status bar at the bottom of the program window. It should read "Completed Query Batch"
- You have just fixed your mapping Error.
LENGTH of the fields may also be a problem. Custom Fields are mapped to Q/A in GOLD. There are only 30 positions allowed for the question and 30 positions for the answer. The Custom Field is the question, so if it is more than 30, the script may fail. For Example:
Shorten:
* Please list the responsibilities of your current position, we would like to know more about your job.
To
*Please list the responsibiliti
Keep in mind that "Please list the responsibiliti" is all that will show up in GOLD after it is truncated at 30 characters. Also, changing the SQL script will NOT affect your data file or the web page. SQL mapping match by position, not actual text.
Need more help? Contact ISIS Corp. at 201-337-8115 ext.19 for support or E-mail support@isisgold.com.
|