Import Tab delimited file through Teradata fast load utility is not working.

Teradata Applications

Import Tab delimited file through Teradata fast load utility is not working.

I am facing an issue in executing below scritp  through fast load utility for tab delimited .txt file

1. First issue in .RECORD 1;

2. IF I remove .RECORD 1; from the code, I am getting "Specified string does not have matchSpecified string does not have match FDL4800 Invalid FastLoad statement" 

Please help on this issue.

.SESSION 4;

.LOGON server/user;

BEGIN LOADING TABLENAME

.RECORD 1;

.IMPORT INFILE name_arch FORMAT VARTEXT '09'XCV";

DEFINE

COLUMN1 VARCHAR (10)),

COLUMN2 VARCHAR (10)),

COLUMN3 VARCHAR (10)),

COLUMN4 VARCHAR (10)),

COLUMN5 VARCHAR (20)),

COLUMN6 VARCHAR (10)),

COLUMN7 VARCHAR (5)),

COLUMN8 VARCHAR (30)),

COLUMN9 VARCHAR (10)),

COLUMN10 VARCHAR (10)),

COLUMN11 VARCHAR (20)),

COLUMN12 VARCHAR (20)),

COLUMN13 VARCHAR (10)),

COLUMN14 VARCHAR (20)),

COLUMN15 VARCHAR (10))

FILE="C:\sample.txt"

.BEGIN LOADING TABLE_NAME

INSERT INTO TABLE_NAME

VALUES

(

:COLUMN1,

:COLUMN2,

:COLUMN3,

:COLUMN4,

:COLUMN5,

:COLUMN6,

:COLUMN7,

:COLUMN8,

:COLUMN9,

:COLUMN10,

:COLUMN11,

:COLUMN12,

:COLUMN13,

:COLUMN14,

:COLUMN15

);

END LOADING;

.LOGOFF;

4 REPLIES
Senior Apprentice

Re: Import Tab delimited file through Teradata fast load utility is not working.

There's a missing semicolon:

.BEGIN LOADING TABLENAME;
.RECORD 1;
.IMPORT INFILE name_arch FORMAT VARTEXT '09'XCV";

Re: Import Tab delimited file through Teradata fast load utility is not working.

Thanks a lot. It works great now.

Re: Import Tab delimited file through Teradata fast load utility is not working.

Hi Team,

I am able to execute the script successfully now but 60% of records go to error table2 and only 40% records inserted into actual table. I am not able to find any difference in records inserted into error and actual table.

Please help to identify the issue.

Teradata Employee

Re: Import Tab delimited file through Teradata fast load utility is not working.

Your target table has a Unique Primary Index and your input has multiple records with the same PI value. For each PI value, one row is loaded and the others go to Error Table 2.