# Data formatter not responding to If/Else statement

**URL:** <https://community.parabola.io/t/data-formatter-not-responding-to-if-else-statement/1036>\
**Category:** Ask a question\
**Tags:** Using-APIs, Building-Flows\
**Created:** [September 4, 2020, 10:30pm UTC](https://community.parabola.io/t/data-formatter-not-responding-to-if-else-statement/1036 "2020-09-04T22:30:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Randy\_H](https://avatars.discourse-cdn.com/v4/letter/r/ad7895/32.png) [@Randy\_H](https://community.parabola.io/u/Randy_H)\
**Post date:** [September 4, 2020, 10:30pm UTC](https://community.parabola.io/t/data-formatter-not-responding-to-if-else-statement/1036/1 "2020-09-04T22:30:01Z")

</div>

Hello,  
I converted both columns into YYYY-MM-DD and the if/then is returning the wrong result. Does anyone know what’s going on?  
Thank you for your help!

 ![Screen Shot 2020-09-04 at 3.29.44 PM](https://us1.discourse-cdn.com/flex020/uploads/parabola/original/1X/595cb3b42901b5cc12c33b6aae7546f107d9c1fe.png)

---

<div class="post-metadata">

**Author:** ![sachi](https://sea2.discourse-cdn.com/flex020/user_avatar/community.parabola.io/sachi/32/10_2.png) [@sachi](https://community.parabola.io/u/sachi)\
**Post date:** [September 4, 2020, 11:47pm UTC](https://community.parabola.io/t/data-formatter-not-responding-to-if-else-statement/1036/2 "2020-09-04T23:47:11Z")

</div>

Hi @Randy_H - Thanks for letting us know about this issue. It does look like we’re encountering a bug with our `Insert If/Else column` when it comes to comparing dates. I’ve reported it and we’ll be taking a closer look.

In the meantime, there is a workaround if you know you’re going to be comparing days, but year and month should always be the same.

You can use the `Format Date` step and format your date to just display dates  
 ![Screen Shot 2020-09-04 at 4.45.36 PM](https://us1.discourse-cdn.com/flex020/uploads/parabola/original/1X/d49662fb160285d8dd6ae4432ebe9ba87d9527b1.png)

Comparing by just the dates using the `Insert If/Else column` does work.

I’ll follow up as soon as we’re able to resolve this issue!

---

<div class="post-metadata">

**Author:** ![sachi](https://sea2.discourse-cdn.com/flex020/user_avatar/community.parabola.io/sachi/32/10_2.png) [@sachi](https://community.parabola.io/u/sachi)\
**Post date:** [October 20, 2020, 8:41pm UTC](https://community.parabola.io/t/data-formatter-not-responding-to-if-else-statement/1036/3 "2020-10-20T20:41:56Z")

</div>

Hey @Randy_H - Just following up to let you know that we’ve released an improvement to the `Insert If/Else column` step to handle date comparisons, number comparisons, and currency comparisons more elegantly! Now, you can compare dates formatted as YYYY-MM-DD with other dates formatted as YYYY-MM-DD.

I know you already have a workaround for this particular solution, but hope you find this useful for future building!
