One row of many randomly not showing correct value

See attached. Can someone help me understand why this one row of all of the rows present will not show the correct amount/format?

For reference, I’m showing the total cost of an item pulled from a receipt using OpenAI. If we can’t automatically pull it, it can be manually entered, then I use an If-Then-Else column to pull the correct number from the two, then a math column to convert to the final format.

Looks like a problem with locale – I am guessing it’s getting the text “$1,039” from the receipt, which is turning into the number 1.039 for some reason, and being rounded to 1.04 for display purposes.

I bet if the text were “$1,039.00” it would work – that’s what’s happening in the other cases containing a comma.

You could use the Text to Number Glide AI column (or even an If Then Else) to normalize the price before converting it with the Math function.

Will try this. But to be honest, there’s some wonkiness happening right now that I haven’t experienced before, in addition to the price issue. Here’s another.

I do the same thing as above, only for the purchase date. As you can see, works beautifully and reliably until the last 3 rows today, where two of them were left blank for no discernable reason. :thinking:

Actually, to be clear, this is what I do. I use an If-Then-Else column before converting it with Math column.

Looks like you have a big mix of formats. Try to make them uniform using Text to Date and Text to Number

Unfortunately, I can’t upgrade to Pro just yet so trying that functionality will have to wait. So is that what you think is happening, just too much going on to reliably log everything accurately?

You are converting from text containing dates and numbers in many different formats–some with times, some without. Some of them do not match your locale. So it’s not figuring it out. You could figure this out with more If Then Else columns that check and normalize the text for free (I am not going to tell you how, it will take an hour :wink:

1 Like

No need to tell me how, I’ll figure it out and we can close the loop on this.

But FWIW so you and the team have it - The data does not show in the editor nor in the interface on desktop web (Arc browser), but it does show up in the interface on iPhone web (safari). :man_shrugging: If the data that would serve this info is blank in the editor, how is it displaying correctly when opened on iPhone browser?


I suspect you’ll find that’s due to variations in the way that devices/browsers recognise dates based on their regional/locale settings.

Ok, thanks Darren. Can you explain or point me to documentation about locale that keeps being referenced? Want to make sure I’m implementing this correctly.

Also, for the record, I do not want or need to ever include times - I just need date. But for some reason the Glide editor does not allow date selection without appending a time. Am I wrong about that?

I don’t know that this is specifically documented anywhere, it’s just something that some of us have learned through (sometimes painful) experience.

Yes, that’s correct. Glide always stores a date/time under the hood. You can format a date/time column as Date Only or Time Only, but that doesn’t change the underlying value.

Just getting back to the dates shown in your earlier example, am I correct in saying that the AI integration is extracting those dates for you?

Assuming that’s correct, I would try instructing the AI to return all dates in YYYYMMDD format. This will ensure that you always get non-ambiguous dates. For example, in the 2nd row of your Purchase Date column, I see 04/02/2023. Is that 4th February, or 2nd April? It could be either, and devices will interpret that one way or the other depending on their locale setting. If you can get the dates returned in YYYYMMDD format, that eliminates that possiblity, and then you can use the Text to Date column to convert that to an actual date value, with midnight as the time.

3 Likes

That’s correct and this did the trick with the dates, thank you!

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