# Field Date - Dates before 1899

**URL:** https://community.glideapps.com/t/field-date-dates-before-1899/65339
**Category:** Report a Bug
**Created:** [August 24, 2023, 10:10am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339 "2023-08-24T10:10:01Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![Tu\_Nacionalidad](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tu_nacionalidad/32/63253_2.png) [@Tu\_Nacionalidad](https://community.glideapps.com/u/Tu_Nacionalidad)
#### Post date: [August 24, 2023, 10:10am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/1 "2023-08-24T10:10:01Z")

</div>

I have an app for genealogical research. My customers need documents about their parents born, and then, need put dates before 1899.

The field Date dont allow put dates before 1899, for me this is an bug or issue before.

Thank,  
Best Regards,

---

<div class="post-metadata">

### Author: ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)
#### Post date: [August 24, 2023, 10:24am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/2 "2023-08-24T10:24:28Z")

</div>

The DatePicker wont allow you to select dates prior to 1900, but they are supported in the Glide Data Editor.

So what you could do as a work around is enter the date as a number, and then use the Text to Date column to convert that number to a valid date.

For example, let’s say you want to enter the date 27th June 1632 - use a Number Input component to enter it as 16320627 (YYYYMMDD), and then convert it.

Here is how that looks:

![CleanShot 2023-08-24 at 18.22.47@2x](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/b/d/bd618c73a38f18a1c55cba9d794b78cb2908ddb2.png)

 ![CleanShot 2023-08-24 at 18.23.19@2x](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/9/c9b4fb3253273c322613573679df7bf35b6329cc.png)

---

<div class="post-metadata">

### Author: ![Tu\_Nacionalidad](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tu_nacionalidad/32/63253_2.png) [@Tu\_Nacionalidad](https://community.glideapps.com/u/Tu_Nacionalidad)
#### Post date: [August 24, 2023, 10:31am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/3 "2023-08-24T10:31:18Z")

</div>

Thank you very much for you answer and workaround, but in case of my customer (users of the app) this UX is not possible. I guess the best option for now is to leave it as a text type field.

---

<div class="post-metadata">

### Author: ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)
#### Post date: [August 24, 2023, 10:31am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/4 "2023-08-24T10:31:57Z")

</div>

Why is it not possible?

---

<div class="post-metadata">

### Author: ![gvalero](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/gvalero/32/1037_2.png) [@gvalero](https://community.glideapps.com/u/gvalero)
#### Post date: [August 24, 2023, 9:21pm UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/5 "2023-08-24T21:21:52Z")

</div>

Hola!

If you don’t want to follow Darren’s suggestion and do it manually, you can use this JS code to validate user input and get a valid date in most cases.

```auto
var date=p1.split("/").map(Number)
let dd=date[0], mm=date[1], yy=date[2];

let myDate= yy+"/"+mm+"/"+dd;

// Check if all values are Number and the Date is valid
if (!yy || !mm || !dd || isNaN(new Date(myDate)))
   return "Error"
else 
   return myDate

```

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/b/6/b6295a1abe4e9a6b6ee14309b072ef56c06c4a00.png)

Due to you are in Spain (I guess so) and use the **DD/MM/YYYY** format, your Date column (text) will accept values only in this format and if everything is fine, you will have a new value but with **YYYY/MM/DD** format if you want to keep/use it on your APP.

Espero te sirva… saludos!

,

---

<div class="post-metadata">

### Author: ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)
#### Post date: [August 25, 2023, 1:54am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/6 "2023-08-25T01:54:32Z")

</div>

I wasn’t necessarily suggesting that anything be done manually 😉

---

<div class="post-metadata">

### Author: ![Tu\_Nacionalidad](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tu_nacionalidad/32/63253_2.png) [@Tu\_Nacionalidad](https://community.glideapps.com/u/Tu_Nacionalidad)
#### Post date: [August 25, 2023, 5:41am UTC](https://community.glideapps.com/t/field-date-dates-before-1899/65339/7 "2023-08-25T05:41:39Z")

</div>

Muchas gracias Gustavo 😉
