INTERACT FORUM

More => Old Versions => Media Center 17 => Topic started by: BartMan01 on April 23, 2012, 01:29:21 pm

Title: Format Date not working properly? [Solved]
Post by: BartMan01 on April 23, 2012, 01:29:21 pm
Trying to use FormatDate in a rename process.

Current usage is FormatDate([Date],yyyy-MM-dd).  Used to take the [Date] field and format, not working now.

Value in Date field =  04/01/2012.
FormatDate([Date]) = 4_1_2012
FormatDate([Date],yyyy-MM-dd) = 1900-01-03

This is with version 17.0.122

I saw another post mentioning changes to these functions, but no specifics on how FormatDate changed.
Title: Re: Format Date not working properly?
Post by: Matt on April 23, 2012, 01:32:40 pm
You need to work on the raw data, not the date formatted for display.

In other words, use this (notice the 0 after the Date field):
FormatDate([Date, 0], yyyy-MM-dd)

Title: Re: Format Date not working properly?
Post by: BartMan01 on April 23, 2012, 01:41:37 pm
You need to work on the raw data, not the date formatted for display.

In other words, use this (notice the 0 after the Date field):
FormatDate([Date, 0], yyyy-MM-dd)



Thanks. [Date, 0] instead of [Date] did the trick.