Fastload via Teradata Client

Database
Teradata Employee

Fastload via Teradata Client

Hi,

I have Teradata Demo CD installed at my PC. I am trying to fast load a text file into a table by following method:

From Start - Programs - Teradata Client - Fastload I run following steps:
********** SCRIPT START*************************
.logon xxxx/username,password ;

Database DB1 ;

Define start_date (Char(8)),
end_date (Char(8)),
bus_date (char(8))
File = C:\Documents and Settings\Desktop\Temp1.txt ;

Begin loading DB1.test_fload errorfiles test_err1,test_err2 ;

Insert into DB1.test_fload
values (:start_date
,:end_date
,:bus_date ) ;

End Loading ;

.Logoff ;

********** Table Definition: *************************

CREATE TABLE DB1.test_fload, no FALLBACK,
no AFTER journal,
no BEFORE journal,
checksum=default
(start_date date NOT NULL,
end_date date NOT NULL,
bus_date date
)
;

********** File Values *************************
2007041420070501
200704032007050120071101
200704182007050120071109
200704012007050120070919
200704022007050120070902
200703292007050120070815
200704042007050120071108
200704072007050120071221
2007041720070501
2007040920070501
200703312007050120070126
2007041520070501
2007041020070501
200704132007050120071224
2007040520070501
200703282007050120070406
2007041120070501
2007041220070501
200703302007050120070101
200704082007050120071225
2007040620070501
200704162007050120071231

The file is a fixed format file
*************** ERROR *********************
**** 11:43:06 I/O Error on File Read: 16, Text: Unexpected data format

Then I tried with changing following insert statement-
Insert into DB1.test_fload
values (:start_date (format 'yyyy-mm-dd')
,:end_date (format 'yyyy-mm-dd')
,:bus_date (format 'yyyy-mm-dd')
) ;

and the error was :
3527 error - Format string 'YYYY-MM-DD' has combination of numeric, character and GRAPHIC values

Please can you advise?
1 REPLY
Teradata Employee

Re: Fastload via Teradata Client

Try
:start_date (date, format'yyyymmdd')
etc.