Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

teradata BTEQ script data file?

Status
Not open for further replies.

virgilioso

Programmer
Apr 21, 2002
2
PH
Can anyone give me an answer on why this aint working?
Produces an error:
*** Error: Import data record not terminated with LF or CF!
// FIRST FILE (bteq script)
.SET SESSIONS 8
.LOGON tera1/name,secret

DATABASE jan_db;

.IMPORT DATA FILE = department.input
.REPEAT *

USING my_department_number(char(4)),
my_department_name(char(30)),
my_budget_amount(char(7)),
my_manager_employee_number(char(4))

INSERT INTO department(
department_number,
department_name,
budget_amount,
manager_employee_number)
VALUES
:)my_department_number,
:my_department_name,
:my_budget_amount,
:my_manager_employee_number
);
.LOGOFF;

// SECOND FILE (data file, department.input)
1 zebrinny 1000.1 1000
2 zebroid 999.11 1005
3 zebrula 998.12 1010
 
Try adding a 2 char filler field as the last field in the Using clause for the CFLF at the end of each row.

USING my_department_number(char(4)),
my_department_name(char(30)),
my_budget_amount(char(7)),
my_manager_employee_number(char(4)),
line_term (char(2))

 
still produces the same error, i think the above applies to fastload.
 
Do you have a "blank" record and a CRLF at the bottom of your input data set? Make sure the data ends at the last data row.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top