Help

Input date just as YYYY?

Topic Labels: Dates & Timezones
Solved
Jump to Solution
1047 4
cancel
Showing results for 
Search instead for 
Did you mean: 
Lisa_Shiota
4 - Data Explorer
4 - Data Explorer

Hi! I’m working on a historical database and am putting in birth and death dates for historical figures. I currently have those field types set as dates (YYYY-MM-DD). However, there are birth/death dates for which I don’t know the months or days for these people. Is there any way to input a date as just the year (YYYY) in records where I don’t know the month or day for these fields? Thanks!

1 Solution

Accepted Solutions
kuovonne
18 - Pluto
18 - Pluto

No, there is not a way to input a date as just a year, without a month and year.

In cases like this where you might not know the full date, I recommend having a combination of inputs, and then using formulas.

  • For example, instead of a date field, you could have three fields, one for year, one for month, and one for day. Then you could have a formula field that calculates the date (when possible).

  • Or you could have a date input field for when the exact date is known, and a separate year field for when the exact date is not known. Then have a formula field that pulls the year from whichever field has a value.

See Solution in Thread

4 Replies 4
kuovonne
18 - Pluto
18 - Pluto

No, there is not a way to input a date as just a year, without a month and year.

In cases like this where you might not know the full date, I recommend having a combination of inputs, and then using formulas.

  • For example, instead of a date field, you could have three fields, one for year, one for month, and one for day. Then you could have a formula field that calculates the date (when possible).

  • Or you could have a date input field for when the exact date is known, and a separate year field for when the exact date is not known. Then have a formula field that pulls the year from whichever field has a value.

Thanks for responding! I’m trying to think this through. What formula would I use to calculate a date if I were to have three separate fields for year, month, and day?

You would use DATETIME_PARSE()

For example, assuming that the day, month, and year are numbers …

DATETIME_PARSE({Day} & "/" & {Month} & "/" & {Year}, 'D-M-YYYY')

If you want to use single select fields for the month, things get a bit more complex.
You may also want to do some data validation in case people enter invalid dates.

The details are in the formula field reference.

Thanks again for your help, @kuovonne!