Errorcode 3798

Tools
Enthusiast

Errorcode 3798

Hi All,

I'm getting 3798 errorcode while running fast-export script. Fast export script contains around 400 columns and have used 25 columns as a group and then concatenate it with another group of 25 columns and so on and as a result getting 3798 error. I tried diving the query into two but again it is very time consuming process and have to rename all columns in order to join on PI. Also I need to get Col1-Col200 from 1st derived table and Col2-Col200 from next table. Please find below a snipet of the query.

SELECT DISTINCT 

('¿'||'|'||

COALESCE(TRIM(COL1),'')||'|'||COALESCE(TRIM(COL2),'')||'|'||COALESCE(TRIM(COL3),

'')||'|'||COALESCE(TRIM(COL4),'')||'|'||COALESCE(TRIM(COL5),

'')||'|'||COALESCE(TRIM(COL6),'')||'|'||COALESCE(TRIM(COL7),

AND SO ON,

'')||'|'||'¿'

) (CHAR(63604))

FROM TBL;

2 REPLIES
Junior Contributor

Re: Errorcode 3798

If you hit the VarChar limit, there's no workaround.

But you might simply switch to TPT which allowes exporting VarText without any manual concat within your query...

Enthusiast

Re: Errorcode 3798

I've got the workaround by dividing the table into two. Created some macros to do the manual tasks. My organization doesn't support TPT. So can't go for it. Thanks btw.

Can you please give me a solution for my other query (https://community.teradata.com/t5/Teradata-Studio/Count-of-working-day/m-p/72819)