can someone please help with this error in tpt???

Teradata Applications
Teradata Employee

can someone please help with this error in tpt???

TPT_INFRA: TPT04111: Error: Line 13 of Job Script File 'tpt_stream.tpt':
Semantic error: schema 'Acc_Schema' is not defined.

4 REPLIES
Teradata Employee

Re: can someone please help with this error in tpt???

This is my entire tpt stream script

 

DEFINE JOB Trickle_Load_New_Transactions_Into_Accounts
DESCRIPTION 'Add new transactions'
(
DEFINE SCHEMA Acc
(
Account_Number INTEGER,
Street_Number INTEGER
);

DEFINE OPERATOR File_Reader
TYPE DATACONNECTOR PRODUCER
SCHEMA Acc_Schema
ATTRIBUTES
(
VARCHAR FileName= 'accounts_data.text',
VARCHAR Format = 'DELIMITED',
VARCHAR OpenMode = 'Read',
VARCHAR TextDelimiter = '|'
);

DEFINE OPERATOR Stream_Accounts
TYPE STREAM
SCHEMA Acc
ATTRIBUTES(
VARCHAR UserName= 'sysdba',
VARCHAR UserPassword= 'learning',
VARCHAR Tdpid= '192.168.126.128',
VARCHAR LogTable='Acc_Stream_Log',
INTEGER MaxSessions= 8,
VARCHAR Pack=20,
INTEGER Rate=20000,
INTEGER Periodicity=10
);
APPLY
('INSERT INTO DS.Accounts (Account_Number,
Street_Number )
VALUES (:Account_Number, :Street_Number);')
SERIALIZE ON (Account_Number)
TO OPERATOR (Stream_Accounts[1])
SELECT Account_Number,Street_Number FROM OPERATOR(File_Reader[1] );

Teradata Employee

Re: can someone please help with this error in tpt???

please someone help me with this its urgent..

Teradata Employee

Re: can someone please help with this error in tpt???

SCHEMA name given as Acc but you have mentioned in file reader operator schema as "SCHEMA Acc_Schema" in line 11 replace it with "SCHEMA Acc" it will work.

Teradata Employee

Re: can someone please help with this error in tpt???

Hi , This is the issue because your Schema name in every operator should be same such as for connector operator, update operator, file reader operator etc, every operator should be named as same " SCHEMA  Acc" and in your case the file reader operator has name asSCHEMA Acc_Schema