CPYTOIMPF CL command
I am generating a flat file from an RPG 400 program. I want to convert the character set of that file to utf-8 or utf-16. Secondly, I want to insert a carriage return to the end of each record. The flat file has the column delimiter as ','.
I?d also like to know how to use the command "CPYTOIMPF". I have tried using it by giving the required parameters, but it gives me a error of reason code 11. I am not able to run it successfully.
Here's an example of the CPYTOIMPF CL command. Error code 11 means that the Record Delimiter parameter on your CPYTOIMPF correct is invalid. CPYTOIMPF FROMFILE(lib1/file1) TOSTMF('/d2') STMFCODPAG(1208) RCDDLM(*CR)
Dig Deeper on DB2 UDB (universal databases)
Related Q&A from Kent Milligan
To solve the SQL error -321 on IBM i6.1, use the new values statement to overcome the error. If you are using an older release, declare a cursor ... Continue Reading
When working with DB2 files with columns that have both short and long names, there is no option choose which column names are returned via ODBC ... Continue Reading
When developing tables in a parent-child relationship, use a primary key and a foreign key along with a unique ID to make your database easier to ... Continue Reading