Validating Date
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
Validating Date
Hi,
Could any one help me out in validating a date column of a CSV file .
the date format in the column is mm/dd/yyyy......
and i need to validate the date if it is a valid date or not.
thanks,
Could any one help me out in validating a date column of a CSV file .
the date format in the column is mm/dd/yyyy......
and i need to validate the date if it is a valid date or not.
thanks,
Shivaranjani
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 612
- Joined: Thu May 03, 2007 4:59 am
- Location: Melbourne
Use IsValid() function.
If your input date is not in date format you might want to convert it and use - IsValid('date',StringToDate(InputLink.Date,"%yyyy%mm%dd"))
If your input date is not in date format you might want to convert it and use - IsValid('date',StringToDate(InputLink.Date,"%yyyy%mm%dd"))
Joshy George
<a href="http://www.linkedin.com/in/joshygeorge1" ><img src="http://www.linkedin.com/img/webpromo/bt ... _80x15.gif" width="80" height="15" border="0"></a>
<a href="http://www.linkedin.com/in/joshygeorge1" ><img src="http://www.linkedin.com/img/webpromo/bt ... _80x15.gif" width="80" height="15" border="0"></a>
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
I am reading the date column as varchar but not as date, then will this syntax work IsValid('date',StringToDate(InputLink.Date,"%yyyy%mm%dd"))
JoshGeorge wrote:Use IsValid() function.
If your input date is not in date format you might want to convert it and use - IsValid('date',StringToDate(InputLink.Date,"%yyyy%mm%dd"))
Shivaranjani
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM
Hi,
Since i am gettin the dates as d/m/yyyy its not matching with the mask dd/mm/yyyy....
so i have picked up the d and padded it with 0 so that it matches dd and the same way for month as well.
Thanks for the help its working.
Since i am gettin the dates as d/m/yyyy its not matching with the mask dd/mm/yyyy....
so i have picked up the d and padded it with 0 so that it matches dd and the same way for month as well.
Thanks for the help its working.
chulett wrote:No.
Does 'yes' mean it is working for you now? If so, please mark the thread as Resolved. If not, please explain what issue remains. ...
Shivaranjani
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 137
- Joined: Sun Jan 07, 2007 11:17 pm
- Location: VISAKHAPATNAM