# Date calculation incorrect

**URL:** <https://community.glideapps.com/t/date-calculation-incorrect/56192>\
**Category:** Ask for Help\
**Created:** [December 31, 2022, 7:16am UTC](https://community.glideapps.com/t/date-calculation-incorrect/56192 "2022-12-31T07:16:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![abdo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/abdo/32/36540_2.png) [@abdo](https://community.glideapps.com/u/abdo)\
**Post date:** [December 31, 2022, 7:16am UTC](https://community.glideapps.com/t/date-calculation-incorrect/56192/1 "2022-12-31T07:16:06Z")

</div>

any idea why I am getting an incorrect computed column result in Glide

the columns checks if this date  
12/31/2022 9:23:13  
is on or before this date  
12/31/2022 9:20:59

and is returning true !

These date values are from the Google Sheet.  
Both dates updated by same user using same time zone. What could possibly be the case?

---

<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:** [December 31, 2022, 7:43am UTC](https://community.glideapps.com/t/date-calculation-incorrect/56192/2 "2022-12-31T07:43:27Z")

</div>

The “on” part of “on or before” only considers the date, not the time.  
So the result you get is correct.  
Probably what you want to use is just “before”.

 ![Screen Shot 2022-12-31 at 3.42.38 PM](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/9/7/97bab4357e68684c43d5e0bcb0ca1b6bfbc39ee0.png)

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/system/32/53398_2.png) [@system](https://community.glideapps.com/u/system)\
**Post date:** [January 2, 2023, 4:40am UTC](https://community.glideapps.com/t/date-calculation-incorrect/56192/3 "2023-01-02T04:40:32Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
