# Glide reads blank search query (with reference to cell)

**URL:** <https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837>\
**Category:** Ask for Help\
**Created:** [February 22, 2022, 3:49pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837 "2022-02-22T15:49:54Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Marco\_Antonio\_Gismon](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/marco_antonio_gismon/32/39464_2.png) [@Marco\_Antonio\_Gismon](https://community.glideapps.com/u/Marco_Antonio_Gismon)\
**Post date:** [February 22, 2022, 3:49pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/1 "2022-02-22T15:49:54Z")

</div>

Guys, how are you? I have a problem.  
I have this formula`=IFERROR(QUERY({GEOLOCALIZACAO!A2:G};“select \* where Col5 contains **‘20220218’** AND Col6 contains ‘MORNING’”);"")

When I use single quotes and put the date I want manually, it works. When I refer to a cell, the glide returns the query blank.  
=IFERROR(QUERY({GEOLOCALIZACAO!A2:G};“select \* where Col5 contains **“&L2&”** AND Col6 contains ‘MORNING’”);"")

What am I doing wrong?

---

<div class="post-metadata">

**Author:** ![Eric\_Penn](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/eric_penn/32/73888_2.png) [@Eric\_Penn](https://community.glideapps.com/u/Eric_Penn)\
**Post date:** [February 22, 2022, 8:18pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/2 "2022-02-22T20:18:32Z")

</div>

You’ll need to use a simple comparison operator.

I.e. \<=, \<, \>, \>=, =, !=, \<\>

Something like

=Query(A2:B,“Select \* where A \<= date '”&TEXT(D1,“yyyy-mm-dd”)&"’")

---

<div class="post-metadata">

**Author:** ![Marco\_Antonio\_Gismon](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/marco_antonio_gismon/32/39464_2.png) [@Marco\_Antonio\_Gismon](https://community.glideapps.com/u/Marco_Antonio_Gismon)\
**Post date:** [February 24, 2022, 2:33pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/3 "2022-02-24T14:33:08Z")

</div>

Tks…  
I tried and it didn’t work. The cell I’m looking for has the formula =Today().  
Is it because of that?

---

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [February 24, 2022, 2:56pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/4 "2022-02-24T14:56:09Z")

</div>

Is this something that would be much better off using Glide’s built in functionality? This like something that could be easily achieved with relation and lookup columns. Or are you trying to avoid directly associating the GEOLOCALIZACAO sheet with the glide app?

---

<div class="post-metadata">

**Author:** ![Marco\_Antonio\_Gismon](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/marco_antonio_gismon/32/39464_2.png) [@Marco\_Antonio\_Gismon](https://community.glideapps.com/u/Marco_Antonio_Gismon)\
**Post date:** [February 24, 2022, 5:25pm UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/5 "2022-02-24T17:25:17Z")

</div>

I have a tab called morning where I look for two pieces of information: today and morning in the Geolocation tab. I need to return only the lines that contain this information.

---

<div class="post-metadata">

**Author:** ![Marco\_Antonio\_Gismon](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/marco_antonio_gismon/32/39464_2.png) [@Marco\_Antonio\_Gismon](https://community.glideapps.com/u/Marco_Antonio_Gismon)\
**Post date:** [February 25, 2022, 1:13am UTC](https://community.glideapps.com/t/glide-reads-blank-search-query-with-reference-to-cell/38837/6 "2022-02-25T01:13:36Z")

</div>

It works…
