473,406 Members | 2,705 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

cli load question

We are using cli bulk loader to load data into db2. In some cases the rows
get rejected and this is flagged as a warning
allowing the program to continue.

Is there any way to trap this warning, I read the use of "EXCEPTION TABLE"
but that is limited to only unique index
violations and not constraint related errors.
How do we handle or capture the rejected records in an elegant way?

Thanks in advance,
Sumanth
May 31 '06 #1
1 1665
I don't know how "elegant" you want the capture to be but an easy way is
to pipe the output of LOAD to a file and parse the errors out of it.
These errors refer to records in a file which are not something handled
in the database. Most of the errors I've seen like this are formatting
errors - alphabetic data in a numeric column. A frequent cause of this
is a character column that contains an apostrophe - the same character
used as a delimiter for character data.

Constraint related errors are a different issue. A table that contains
constraints that is the target of a LOAD operation will be placed in
"check pending" state. You need to run the SET INTEGRITY command against
the table to locate and handle these errors. Set integrity has an option
to delete the rows failing constraint checks and move them to a work
table. There's no reason this couldn't be the same table that you used
for the "exception table" during LOAD processing.

Unfortunately, when there are multiple check constraints, there's no way
to tell which one caused the row to be deleted from the LOAD target
table. I usually try to scrub data before loading rather than have LOAD
catch all of the errors.
Phil Sherman

Sumanth wrote:
We are using cli bulk loader to load data into db2. In some cases the rows
get rejected and this is flagged as a warning
allowing the program to continue.

Is there any way to trap this warning, I read the use of "EXCEPTION TABLE"
but that is limited to only unique index
violations and not constraint related errors.
How do we handle or capture the rejected records in an elegant way?

Thanks in advance,
Sumanth

May 31 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Max | last post by:
Frankly, i need session variables to persist regardless of load balancing. My hoster says save them in files, yuk. Are there any other thoughts The problem is that the session variables are lost...
6
by: Shabam | last post by:
A web application of mine developed using C# + MS SQL runs fine normally. However when I stress test it with a load testing software (using about 60 simultaneous users) some instances start...
1
by: paul-esposito | last post by:
Okay, so I'm the DBA not a developer, but I need a sanity check. All the data access to the database is controlled by Stored Procedures, the procedures are really granular, basically every table...
2
by: Lee Alexander | last post by:
Why does Assembly.Load allow this: Assembly.Load( "mscorlib" ); if you try the following it fails as expected: Assembly.Load( "System" ); Since it should be (for framework 1.1):...
7
by: Dan Nash | last post by:
Hi guys Ok, i have an aspx with a user control. In the user controls pageload i set a property (mystring = "test";). i then want to access that from the page_load of the aspx thats using the...
1
by: Jerry LeVan | last post by:
At the time I built Postgresql 7.4.2 I did not have aqua Tcl/Tk installed. The Aqua Tcl/Tk version installs in a different location the the apple supplied Tcl ( apple does not supply Tk). I...
7
by: P. Adhia | last post by:
Sorry for quoting an old post and probably I am reading out of context so my concern is unfounded. But I would appreciate if I can get someone or Serge to confirm. Also unlike the question asked in...
1
by: huyuhui | last post by:
The following is a question of LOAD utility. Question: How does the DB2 enforce table check constraints for data added to table with the LOAD utility? A. With the BUILD phase of LOAD B. With the...
1
by: charlie imac | last post by:
I have a question on the capability of Ajax. My question is: Is it possible to dynamically load any of the javascript gallery programs such as: Adobe Spry Gallery SmoothGallery others I...
5
by: BerlinBrown | last post by:
Do you know if it is possible to wait for the iframe page to load and then manipulate the iframe DOM. E.g. mypage: <script> function myinit() { theiframe.location = "iframe_with_frames.html"...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.