MyRapidi
MyRapidi

Search our Wiki

TODATE

TODATE(date, month, year);

The function Todate can be used if you want to transfer date, month and year to a single field in the destination.

 

Example:

Source holds day, month and year in separate fields which needs to be transferred into a Date field in the destination:

 

sDay=15
sMonth=05
sYear=2009

 

##TODATE("sDay","sMonth","sYear")
Returns the value = 15-05-2009.

 

If that format does not match date in the destination Data Base you can add a FORMAT formula:

 

 ##FORMAT(TODATE"sDay","sMonth","sYear"),'%Y%m%d')
Returns the value = 20090515.

 

If you need a specific separator you can add that in the formula:

 

##FORMAT(TODATE("sDay","sMonth","sYear"),'%Y-%m-%d')
Returns the value = 2009-05-15.

 

You can have year into digits (o3) by using y instead of Y:


##FORMAT(TODATE("sDay","sMonth","sYear"),'%y-%m-%d')
Returns the value: 09-05-15