My textfile got around 140,000 lines.
It is a fixed length file where i retrieve from a mainframe.
I put it under a Sequential file with format :
Record delimiter = UNIX newline
Delimiter = None
However , after i run the job , the result over the DSLink shows only 125,000 rows , 3800 rows/sec.
Is this mean only 125,000 lines of data being insert into my db2 ?
(by the way im new to db2 , how can i know total of rows of the table in db2?)
The 15,000 lines is being rejected when insert into db2 for what reason?
Thanks
Some lines of data missing when inserting into DB2
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 63
- Joined: Mon Sep 12, 2011 2:11 am
Re: Some lines of data missing when inserting into DB2
Hi kanasai167
getting the number of rows in a able is a simple SQL statement:
select count(*) from <schemaname>.<tabname>
Rows can get rejected if there is a unique contraint on the table or something similar.
Contact your DBA for further details
getting the number of rows in a able is a simple SQL statement:
select count(*) from <schemaname>.<tabname>
Rows can get rejected if there is a unique contraint on the table or something similar.
Contact your DBA for further details
regards
Michael
Michael
-
- Participant
- Posts: 63
- Joined: Mon Sep 12, 2011 2:11 am
thanks for the help on the count of rows.
im creating a new table to store the data from a fixed length textfile.
Im using the DB2 UDB API to insert the data into db2 by turning on the generate DDL to create table.
How should i remove the unique contraint ? Is it on the source(textfile) or the destination(db2 table) ?
im creating a new table to store the data from a fixed length textfile.
Im using the DB2 UDB API to insert the data into db2 by turning on the generate DDL to create table.
How should i remove the unique contraint ? Is it on the source(textfile) or the destination(db2 table) ?
Do you define a primary key for your table? If yes, then you have a unique contraint.
But are you sure that you read ALL 140.000 records from the source succesfully?
What is the record count from the source output link? Try to put a reject link on the sequential file stage and catch for catching any reject due to format issues.
For your target stage then I don't know if it supports reject links, but if it does then add a reject link here as well.
But are you sure that you read ALL 140.000 records from the source succesfully?
What is the record count from the source output link? Try to put a reject link on the sequential file stage and catch for catching any reject due to format issues.
For your target stage then I don't know if it supports reject links, but if it does then add a reject link here as well.
_________________
- Susanne
- Susanne
-
- Participant
- Posts: 63
- Joined: Mon Sep 12, 2011 2:11 am