All Forums Tools
Komal.Dinesh 2 posts Joined 01/14
16 Jan 2014
TPT15105: Error 13 in finalizing the table schema definition

Hi,
I am using Teradata Parallel Transporter SQL Selector Operator Version 13.10.00.12.
I have a table with 5 columns , and have created a view on it for TPT by casting all columns as VARCHAR. A schema file gets created but the utlity fails with the error " TPT15105: Error 13 in finalizing the table schema definition"
I have read the posts regarding this error on this forum and checked the data format with the table definition and it seems to be matching. I have pasted below the table , view and schema definition.
 
Please advise
CREATE MULTISET TABLE TABLE1 ,NO FALLBACK , 
 

     ( 

      Id VARCHAR(20) CHARACTER SET LATIN CASESPECIFIC TITLE 'Application Identifier', 

      User_Id VARCHAR(100) CHARACTER SET LATIN CASESPECIFIC TITLE 'User Identifier' NOT NULL, 

      Role_Cd VARCHAR(100) CHARACTER SET LATIN CASESPECIFIC TITLE 'Role Code' NOT NULL, 

      Role_Nr INTEGER TITLE 'Role Number', 

      Active_Ind CHAR(1) CHARACTER SET LATIN CASESPECIFIC TITLE 'Active Indicator' COMPRESS ('N','Y')) 

PRIMARY INDEX TABLE1 ( User_Id ,Role_Cd ); 

 

REPLACE VIEW VIEW1

AS LOCK ROW FOR ACCESS 

SELECT

   COALESCE(CAST(App_Id AS VARCHAR(20)),'N/A') AS App_Id,

    COALESCE(CAST(User_Id AS VARCHAR(100)), 'N/A') AS User_Id,

    COALESCE(CAST(role_cd AS VARCHAR(100)),'N/A') AS role_cd,

    COALESCE(CAST(role_nr AS VARCHAR(11)), 'N/A') AS role_nr,

    COALESCE(CAST(active_ind AS VARCHAR(1)), 'N/A') AS active_ind

FROM TABLE1;

 

 

DEFINE SCHEMA TABLE1_SCHEMA

DESCRIPTION 'TABLE1 SCHEMA'

   (   App_Id                         VARCHAR(60)

      ,User_Id                        VARCHAR(300)

      ,Role_Cd                        VARCHAR(300)

      ,Role_Nr                        VARCHAR(33)

      ,Active_Ind                     VARCHAR(2)

    );

 

Thanks,

Komal

 

feinholz 1234 posts Joined 05/08
16 Jan 2014

I notice you tripled the size of each column in the schema (probably because you will be using a client session character set of UTF8?), except for the last one (active_ind).
 
Was this on purpose?
 

--SteveF

Komal.Dinesh 2 posts Joined 01/14
17 Jan 2014

Thanks for your response.
Yes , we are using character set of UTF8 and for columns which are of CHAR datatype, are mutiplied only 2.

ratchetandclank 49 posts Joined 01/08
17 Jan 2014

For all character types, while using UTF-8 character set, you have to triple the size. You have tripled it for the first four columns, and have doubled for the last column. 

You must sign in to leave a comment.