Data Access Worldwide Knowledge Base

Article ID 2235
Article Title PROBLEM: DB2 Errors when using BAT generated by Dump and Load option
Article URL http://www.dataaccess.com/kbasepublic/KBPrint.asp?ArticleID=2235
KBase Category CONNECTIVITY KITS
Date Created 08/11/2006
Last Edit Date 07/04/2008


Article Text
PROBLEM 1
Running the script as it was output, I got "SQL3304N The table does not exist."

SOLUTION
The script created did not include the table schema name in the LOAD command. Adding the schema name fixed that error.



PROBLEM 2
After fixing 1, the error "SQL3025N A parameter specifying a filename or path is not valid." was displayed.

SOLUTION
- The script did not include the path to the ".del" file to be loaded in the LOAD command.
- The script did not include the CLIENT option in the LOAD command required when using LOAD from a remote client. (See below)

Adding the path to that file and the CLIENT option to the LOAD command fixed that error.


LOAD Command CLIENT Option

Requirements: IBM DB2 7.1 or later

Specifies that the data to be loaded resides on a remotely connected client. If this option is not specified the data must reside on the server.

For example, the following command allows you to load an ASCII text file located on the client to a remote IBM DB2 database.
    LOAD CLIENT FROM customers.txt OF del MESSAGES customers.log INSERT INTO customers



PROBLEM 3
When running the script, the following error may occur:
SQL0206N  "Recnum" is not valid in the context where it is used. SQLSTATE=42703

SOLUTION
In the script, the LOAD command refers to recnum as "Recnum" -- in title case. To fix the error, change recnum to be all uppercase and no quotes.

Example:
LOAD from orders.del of DEL modified by delprioritychar method P (1, 2, 3, 4, 5, 6) messages dfdb2.log insert into STATES("Recnum", "ONUM", "STATUS", "VENDOR", "CUSTNO", "DATE")

("Recnum", needs to be changed to (RECNUM,





Contributed By:
Marcia Booth
Company: Data Access Worldwide
Web Site: http://www.dataaccess.com


Email this Article
Email this Article to a Colleague
Send Feedback on this Article to Data Access Worldwide
Copyright ©2010 Data Access Corporation. All rights reserved.

The information provided in the Data Access Technical Knowledge Base is provided "as is" without warranty of any kind. Data Access Corporation disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. In no event shall Data Access Corporation or its suppliers be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages, even if Data Access Corporation or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for consequential or incidental damages so the foregoing limitation may not apply.