Search found 6797 matches

by DSguru2B
Fri Jun 08, 2007 7:21 am
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: SQL Code works in Query Analyzer but not ODBC Stage
Replies: 1
Views: 581

They should work. Can you post the complete query here.
by DSguru2B
Thu Jun 07, 2007 1:35 pm
Forum: General
Topic: Function to get the current date only.
Replies: 5
Views: 1194

CurrentDate
CurrentTime
CurrentTimestamp
all of the above are px specific solutions.
by DSguru2B
Thu Jun 07, 2007 12:55 pm
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: Abort a Job if No rows are selected from source
Replies: 9
Views: 7221

You can have an after job subroutine (custom) that check for the link count. If its zero, you can log the error as a fatal error which will cause the job to abort.
Its not a good practice to abort jobs in production.
by DSguru2B
Thu Jun 07, 2007 12:15 pm
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: String to Timestamp Conversion
Replies: 13
Views: 2372

How are you reading it as? Is it varchar? If thats the case then you dont need to do any month or day check. Just send it to StringToTimestamp() with the mask I gave you in my first post. It should work.
by DSguru2B
Thu Jun 07, 2007 12:05 pm
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: String to Timestamp Conversion
Replies: 13
Views: 2372

You need to check if day and month are single digit and only then prefix it with zero. Specify stage variables to fix the day and month StgMonth- If Len(Field(in.Date, "/", 1)) = 1 then "0":in.Date else in.Date StgDay - If Len(Field(StgMonth, "/"...
by DSguru2B
Thu Jun 07, 2007 9:42 am
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: String to Timestamp Conversion
Replies: 13
Views: 2372

You need to work on two things:
1) Check the length of day and month, if its one then prefix it with a zero.
2) Append :00 as seconds to the end.

Then pass it to StringToTimestamp() with the mask of %mm/%dd/%yyyy %hh:%nn:%ss.
by DSguru2B
Thu Jun 07, 2007 7:18 am
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: Error with Date
Replies: 6
Views: 1253

As far as I remember, if its just date "DATE(10)", then db2 accepts it in internal format. If you just sent it as ICONV() it will accept it.
by DSguru2B
Thu Jun 07, 2007 7:16 am
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: Maximum Column length of Hashed File
Replies: 2
Views: 557

What is the maximum that you will expect? Set it to varchar 4000. It should be able to accept that. If thats way, way too much, then set it to varchar 255.
by DSguru2B
Thu Jun 07, 2007 7:11 am
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: Current Month Less 24 months
Replies: 6
Views: 1801

You need to sepcify the conversion mask for your second StringToDate.
by DSguru2B
Wed Jun 06, 2007 8:47 pm
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: How do i find a Job by target?
Replies: 9
Views: 2864

Impressive work leaves a mark forever. We got your back Kim. :wink:
by DSguru2B
Wed Jun 06, 2007 3:13 pm
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: How to assign sequence numbers?
Replies: 7
Views: 944

You can see it now.
by DSguru2B
Wed Jun 06, 2007 2:19 pm
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: Copying set of tables in to different tables
Replies: 12
Views: 1970

You can write a small stored proc. to do that and call the stored proc. from within datastage.
by DSguru2B
Wed Jun 06, 2007 2:18 pm
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: How to assign sequence numbers?
Replies: 7
Views: 944

Well, then just check each incoming value for 400 (if it is static). And if you find 400, increment the counter.
Something like

Code: Select all

If in.Col1 = 400 then counter+1 else counter

Initialize the counter with 0. counter is a stage variable.
by DSguru2B
Wed Jun 06, 2007 1:57 pm
Forum: IBM<sup>®</sup> Infosphere DataStage Server Edition
Topic: How to assign sequence numbers?
Replies: 7
Views: 944

What are the rules of assignment? From the data, what tells you that this is sequence number 1 and this # 2 ?
by DSguru2B
Wed Jun 06, 2007 12:49 pm
Forum: IBM<sup>®</sup> DataStage Enterprise Edition (Formerly Parallel Extender/PX)
Topic: julian to timestamp
Replies: 6
Views: 1656

Cast it As Integer using that function in the transformer stage.