DATE()

Date from Date, DateTime, or Time

Returns Date from Date, DateTime, or Time.

Sample usage

DATE("4/1/2010") returns 4/1/2010

DATE(TODAY()) returns today's date from a Date value. See also: TODAY()

DATE("4/1/2010 3:14") returns 4/1/2010

DATE(NOW()) returns today's date from a DateTime value. See also: NOW()

DATE("3:14") returns 12/30/1899 (a Time value has no date component, so a default is used).

DATE(TIMENOW()) returns 12/30/1899 (TIMENOW() returns a Time value, which has no date component, so a default is used).

Common problems

DATE("Good morning, Martin!") returns blank because the textual input isn't a recognized temporal type and so cannot be converted.

Syntax

DATE(when)

  • when - A Date, DateTime, or Time value.

Notes

To understand how your mobile device's locale or browser's language setting can impact the Date format, see Considerations for apps using Date, Time, and DateTime formats.

Some constant values, such as "MM/DD/YYYY", are evaluated as a Date value by AppSheet. Similarly, "000:00:00" is evaluated as a Duration value. This doesn't mean your spreadsheet data must use the same formats: the date and time formats in your spreadsheets are determined by the locale/language setting. Column will always be evaluated as the type of column. Additionally, you can convert data, both columns and string literals, to specific types using functions such as DATE(), TIME(), or DATETIME()

Because temporal types are Text values with specific formats, any textual value may be supplied to DATE(), but non-temporal values will produce a blank result.

If a Time value is specified, which has no date component, returns a default date of 12/30/1899. If the specified value is not a Date, DateTime, or Time value, returns a blank.

See also

Date and time expressions

Considerations for apps using Date, Time, and DateTime formats

DATETIME()

NOW()

TIME()

TODAY()

Was this helpful?

How can we improve it?

Need more help?

Try these next steps:

true
Search
Clear search
Close search
Main menu
3254480505687722471
true
Search Help Center
true
true
true
false
false