How to capture the warnings

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
Xpert
Premium Member
Premium Member
Posts: 85
Joined: Wed Mar 01, 2006 7:17 am

How to capture the warnings

Post by Xpert »

Hi,

I want to capture the warning messages and i have to load it in a table. if the warning is because of truncation errors, unique constraint, whatever it is? How to capture those warnings?
With regards,
Xpert
pankajg
Participant
Posts: 39
Joined: Mon Jun 05, 2006 5:24 am
Location: India

Post by pankajg »

I think you can do this by using DSGetLogSummary

U wil need to write a routine and use the function DSGetLogSummary, the result of which you can store or write to a file and then load that file into the database.

Check out the BASIC guide for more information on DSGetLogSummary.
Xpert
Premium Member
Premium Member
Posts: 85
Joined: Wed Mar 01, 2006 7:17 am

Post by Xpert »

Hi,

I tried with DSGetLogSummary function, but its giving newest log only. but i want to capture all the warnings. Thanks in Advance.

pankajg wrote:I think you can do this by using DSGetLogSummary

U wil need to write a routine and use the function DSGetLogSummary, the result of which you can store or write to a file and then load that file into the database.

Check out the BASIC guide for more information on DSGetLogSummary.
With regards,
Xpert
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

You can capture the database errors like SQL CODE and SQL ERROR from the job by extendending the reject link with these column enabled using RPC.
If you need to load the logs available from datastage, you can use dsjob -logsum/-logdetail/-lognewest functionality.
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Depending on what stage type you are using, and how you are sending the rows to the table (upsert vs write), there may be an additional column called sqlcode on the reject link.

However, capture of all warnings is probably easiest done by post-processing the job log.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply