on 03-07-2009 6:21 AM
HI,
In my scenario of IDOC to file , there are two input dates start and end date . I need to compare whether these two dates lie within the range of the current date . I mean start date <= current date and end date >= current date then i need to create the segment else it should not be created.
I have tried this using the standard function .I need some help whether we need to go for a UDF for this .
Can anyone send me UDF details on this one.
Hi
Don't post multiple question for the same ..
Check with the node functions . U have BeforeDate , AfterDate .CurrentDate . If condition , and CreateIf .
Using this you can achieve ur goal , just try .
Don't go for UDF Unnecessary.
B.Jude
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the inputs. My problem has been solved.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Amit
you can try & use the folllowing java code
import java.util.Date
Date currDate = new Date();
int i,j;
i = startDate.compareTo(currDate);
j = endDate.compareTo(currDate);
if ((i<=0) & (j>=0)){
resultlist.addValue(' ');
else
resultlist.addSuppress();
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Thanks for your replies .Points are been awarded.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Amit,
You can do it using standar functionality, do like below ,
u have to use createif function and date function.
start date-> ( Equals)-> current date
or ->
start date-> ( BeforeDate)-> current date
and -> creteif -> target Node
end date-> ( Equals)-> current date
or ->
end date-> (AfterDate)-> current date
Hope this will help you !!
Regrad
Biplab
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI ,
This works for few conditions and fails for a few using graphical mapping.
So I want to go for an UDF ..
The condtion is
Startdate <= Currentdate and Enddate >= current date
then pass value
else
do not pass
I need to put this logic under a UDF ..
Can anyone please help on this one
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.