# How to copy a boolean to a different table

**URL:** https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434
**Category:** Ask for Help
**Created:** [April 9, 2024, 7:43pm UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434 "2024-04-09T19:43:50Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Katelyn\_Alberts](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/katelyn_alberts/32/44421_2.png) [@Katelyn\_Alberts](https://community.glideapps.com/u/Katelyn_Alberts)
#### Post date: [April 9, 2024, 7:43pm UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/1 "2024-04-09T19:43:50Z")

</div>

I have a table for promotional offers.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/4/1/41b78d1148a81abb3d52109250dd4a5e5787e7eb.png)

However I only want these promo deals to be visible on the app if the business is active.

I have a boolean for indicating whether or not the business is active BUT it’s located on a different table.

How do I bring that boolean over to this table?

---

<div class="post-metadata">

### Author: ![nathanaelb](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nathanaelb/32/43079_2.png) [@nathanaelb](https://community.glideapps.com/u/nathanaelb)
#### Post date: [April 9, 2024, 10:36pm UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/2 "2024-04-09T22:36:38Z")

</div>

In your Deals table, for each promotional offer (on each row), is it clear which company the promotional offer is for?

If not, you would need a column with the company name or company ID (which would be the Row ID from the companies table). This would allow you to link a deal to its corresponding company.

(The reason it’s preferable to use a company ID rather than a company name is because row ID are unique and won’t change, whereas a company name can be subject to name changes, spelling errors, etc.)

Once the link is clear, you can create a single relation in the deals table pointing to the company table. Then use a lookup column point to the relation to pull in another information you need about the company. In your case whether the business is active or not.

---

<div class="post-metadata">

### Author: ![Katelyn\_Alberts](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/katelyn_alberts/32/44421_2.png) [@Katelyn\_Alberts](https://community.glideapps.com/u/Katelyn_Alberts)
#### Post date: [April 9, 2024, 10:48pm UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/3 "2024-04-09T22:48:35Z")

</div>

hi! thanks nathan! I thought that was the right thing to do, but my lookup column isn’t working. perhaps i set it up wrong.

I have my business (salon) relation set up with the row ID, and then I have a look up column through “salon relation” pointing at the boolean and none of them are checked off?

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

---

<div class="post-metadata">

### Author: ![nathanaelb](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nathanaelb/32/43079_2.png) [@nathanaelb](https://community.glideapps.com/u/nathanaelb)
#### Post date: [April 9, 2024, 10:51pm UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/4 "2024-04-09T22:51:48Z")

</div>

Could you show a screenshot of how you setup the relation between the Deals table and Businesses 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 10, 2024, 12:56am UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/5 "2024-04-10T00:56:44Z")

</div>

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/0/7/07a1de2605067b3ac0d912660beb5f3bdbc0f3e7.png)

You seem to have that logic stored in an If-Then-Else column.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/8/b/8b77f874991f06960c0ef62f4af9674feea7e536.png)

Corrected it.

---

<div class="post-metadata">

### Author: ![Katelyn\_Alberts](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/katelyn_alberts/32/44421_2.png) [@Katelyn\_Alberts](https://community.glideapps.com/u/Katelyn_Alberts)
#### Post date: [April 10, 2024, 1:38am UTC](https://community.glideapps.com/t/how-to-copy-a-boolean-to-a-different-table/72434/6 "2024-04-10T01:38:23Z")

</div>

Thanks guys! @nathanaelb @ThinhDinh
