# Data missing from iPhone app

**URL:** <https://community.glideapps.com/t/data-missing-from-iphone-app/60815>\
**Category:** Ask for Help\
**Created:** [April 21, 2023, 11:39pm UTC](https://community.glideapps.com/t/data-missing-from-iphone-app/60815 "2023-04-21T23:39:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![marshru](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@marshru](https://community.glideapps.com/u/marshru)\
**Post date:** [April 21, 2023, 11:39pm UTC](https://community.glideapps.com/t/data-missing-from-iphone-app/60815/1 "2023-04-21T23:39:18Z")

</div>

Hey - I’m playing with TV streaming app and have a little problem with the iPhone client - it’s not coming back with one particular value and I can’t figure out what I’m doing wrong. The screen should look like this (taken from Glide layout mode on my pc):

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/d/3/d3109063dd24c94c070d56d11b303f169cb7fc66.jpeg)

It shows the day that the series airs next to the service.

on the iPhone it looks like this:

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/d/4/d43179d0eeb0bdf9323498f6e0be9274b2f727b8.jpeg)

The text was originally a template and the weekday was just blank so I created a string in javascript instead to see what, if anything, was there (p1 is the weekday column below, p2 is the watching on text you can see):

> return p1 + "s on " + p2;

The weekday text that shows as “undefined” is a js snippet that looks up a numeric weekday value and returns a corresponding string (p1 is a column containing the date):

> const dt = new Date(p1);  
> const dy = dt.getDay();  
> const dn = [“Sunday”, “Monday”, “Tuesday”, “Wednesday”, “Thursday”, “Friday”, “Saturday”];
> 
> return dn[dy];

The resulting data looks like this:

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/2/c2742d2934f90f08350b8a5b5f393b0e5e2aa90a.png)

Any thoughts on why this not returning a value on the app even though I can see the data on the table?

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [April 21, 2023, 11:49pm UTC](https://community.glideapps.com/t/data-missing-from-iphone-app/60815/2 "2023-04-21T23:49:29Z")

</div>

It is most likely that Safari doesn’t like this part:

```auto
const dt = new Date(p1);
const dy = dt.getDay();

```

Since the way Safari reads dates can be different from other browsers, I learned it the hard way.

I would set it up with a math column to return the weekday, then get the weekday name based on the weekday number instead. Finally, use a template column (you don’t need JS for that) to construct this part.

```auto
return p1 + "s on " + p2;

```

---

<div class="post-metadata">

**Author:** ![marshru](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@marshru](https://community.glideapps.com/u/marshru)\
**Post date:** [April 22, 2023, 12:01am UTC](https://community.glideapps.com/t/data-missing-from-iphone-app/60815/3 "2023-04-22T00:01:12Z")

</div>

Perfect!  
I just did the math fix and it worked. I figured it was Safari but didn’t know how to get to the problem. I should have known better than to rely on the browser to do it.

Thanks so much 😄

By the way - the string construct was a template - I just put it in a js string to see what it returned (not v helpful at the end of the day).
