All Forums Database
Koentje 23 posts Joined 09/04
15 Jan 2009
Fastload from a mainframe (usage comp - format)

How to fastload a USAGE COMP from mainframe to Teradata?An USAGE COMP-3 can be defined as Decimal(12,2) or something like that in the DEFINE section.Signed fields can be loaded by using a FORMAT in the INSERT part (like Format '9999V99S').I tried a lot of things, but fastload is rejecting the records.Any suggestion?

Jim Chapman 449 posts Joined 09/04
15 Jan 2009

I assume you are referring the COMP data type in IBM COBOL, which is a signed binary integer in twos-complement form. It may be 16, 32 or 64 bits wide. In Teradata, it should be declared as BIGINT (64 bits), INTEGER (32 bits) or SMALLINT (16 bits) depending on the width.

Koentje 23 posts Joined 09/04
19 Jan 2009

Thanks for this information but I'm not sure.The definition on mainframe is:10 RMGLV026-AORG-CD PIC X(5). 10 RMGLV026-GLIN-AMT PIC S9(11)V9(2) USAGE COMP.10 RMGLV026-GLIN-AH-SEC-CD PIC X(12). The second field is given problems during fastload.This amount is a decimal field (11 positions before and 2 positions after the decimal point, with a virtual decimal point). Total number of bytes: 8 bytes.Example (HEX display):......ûÙ = EBCDIC000000DF > Hexadecimal: 000000000006DBFD000006BD

You must sign in to leave a comment.