To Compare 2 dates

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

ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I gave my solution 40 minutes ago.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
nikhilanshuman
Participant
Posts: 58
Joined: Tue Nov 17, 2009 3:38 am

Post by nikhilanshuman »

ray.wurlod wrote:I gave my solution 40 minutes ago. ...
That's great.I really appreciate the good contributors like you.Keep up the good work...
Nikhil
radhika7983
Participant
Posts: 16
Joined: Wed Apr 07, 2010 10:44 pm

Post by radhika7983 »

MT wrote:
radhika7983 wrote:
MT wrote:Hi

well I think this comes down to two situations:
1) if the migartion date is a Monday or Tuesday then you will look for a difference of 3

2) if the migration date is Wednesday, Thursday or Friday then use a difference of 5

So you just have to determine the day (name or number) i.e. with oconv

regards
Michael
You mean to say that If my migration date is monday or tuesday than I just need to check for difference of 3 bwteen the 2 dates? If yes, Than I dont think this will work.Suppose my migration date is monday and the other date day is wednesday. In this case the difference is 4 days, but I cannot reject the record because out of days, 2 are saturday and sunday. This record should still pass to output
Hi,

well I do not understand this - sorry..
Let us assume:
Your (fix) migration date is monday.
When other date is (let us say wednesday of the same week) the difference of the two dates has to be checked if it is > 3 then reject it.

In my calender there is no saturday or sunday between monday and wednesday.... ;-)

kind regards
Michael
Well..the other date is less than the migration date...So I was talking about the other date which falls in previous week. It cannot be the same week :) I hope you got it now
Post Reply