DSGetLogSummary info

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
mousazzi
Participant
Posts: 18
Joined: Thu Nov 23, 2006 3:56 am

DSGetLogSummary info

Post by mousazzi »

Hello. I'm using the function DSGetLogSummary inside a before/after subroutine to get specially the SQL statement in the job.
I've redirect the output in a file but the info about sql statement appears as truncate; in the file I've got the rigth statement until the character 166 (more or less) and the there is (...).
Is there a way to improve the buffer dimension ??
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Wouldn't it be more appropriate to use DSGetLogDetail for this?
-craig

"You can never have too many knives" -- Logan Nine Fingers
mousazzi
Participant
Posts: 18
Joined: Thu Nov 23, 2006 3:56 am

Post by mousazzi »

chulett wrote:Wouldn't it be more appropriate to use DSGetLogDetail for this?
Can I use this function in a before/after routine ?? I didn't find anything in the documentation so I suppose it's for command line only...
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

More like, DSGetLogEntry() which works along with DSGetNewestLogId(). Look in the help index for DSGetLogEntry(), it will explain you how to use it. You will then have to create your own after job subroutine that uses these api calls.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
mousazzi
Participant
Posts: 18
Joined: Thu Nov 23, 2006 3:56 am

Post by mousazzi »

DSguru2B wrote:More like, DSGetLogEntry() which works along with DSGetNewestLogId(). Look in the help index for DSGetLogEntry(), it will explain you how to use it. You will then have to create your own after job subroutine that uses these api calls.
Thanks DSguru2B, I'm trying to use it but the problem now is that I can only view one event id and the event is the last one (given by DSGetNewestLogId). Is there a way to have the first and the last event id of my job ??
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Well, you will have to get the eventid before the job starts, store it somewhere (COMMON, USERSTATUS, FLAT FILE etc) and get the last even id and then loop through each while getting the log detail.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Doesn't the Summary call give you the ids for all of the entries? Seems like you could take the ones you are interested in and call DSGetLogEntry specifically for those.
-craig

"You can never have too many knives" -- Logan Nine Fingers
mousazzi
Participant
Posts: 18
Joined: Thu Nov 23, 2006 3:56 am

Post by mousazzi »

DSguru2B wrote:Well, you will have to get the eventid before the job starts, store it somewhere (COMMON, USERSTATUS, FLAT FILE etc) and get the last even id and then loop through each while getting the log detail.
That's fine. I'll operate in this way. It seems to be a good idea. Thanks.
Post Reply