# Preset a value/selection based on existing collection / Separate table

**URL:** <https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215>\
**Category:** Get Help\
**Created:** [July 7, 2022, 11:26pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215 "2022-07-07T23:26:51Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![magoo6617](https://avatars.discourse-cdn.com/v4/letter/m/848f3c/32.png) [@magoo6617](https://forum.adalo.com/u/magoo6617)\
**Post date:** [July 7, 2022, 11:26pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/1 "2022-07-07T23:26:51Z")

</div>

Is there a way to preset (on screen load) the value / selection of a horizontal chip list based on the value in another table/variable? This seems like such a simple/obvious thing, but impossible to achieve…

Scenario: User (collection) logs a daily progress log (collection) of health statuses. These status are entered via a series of chip list selections. When the user revisits a prior day’s log, it is impossible to show what selections were made using the chip list, because there is no way to pre-load those values to that component.

Thank you!

---

<div class="post-metadata">

**Author:** ![Flawless](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/flawless/32/20131_2.png) [@Flawless](https://forum.adalo.com/u/Flawless)\
**Post date:** [July 8, 2022, 10:44am UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/2 "2022-07-08T10:44:15Z")

</div>

You need to have a relationship between users and logs. If they have a date or date/time parameter, you can add the chip list with a filter where “date” is equal to the date you select (maybe like a date picker component.)

Then, you can switch days with the date picker and see the values from any previous day that they’ve entered.

---

<div class="post-metadata">

**Author:** ![magoo6617](https://avatars.discourse-cdn.com/v4/letter/m/848f3c/32.png) [@magoo6617](https://forum.adalo.com/u/magoo6617)\
**Post date:** [July 8, 2022, 3:15pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/3 "2022-07-08T15:15:32Z")

</div>

Thank you for replying. I appreciate the assistance. I understand your suggestions and recognize that this works when I use the default options for those fields within forms. I do have the relationships set up as you suggested. No issue there.

The problem is the way I would like the form to work. I am leveraging the Two-State Chip component from NoCode Monkey [Two-State Chip List for Adalo | NoCode Monkey](https://www.nocodemonkey.io/components/two-state-chip-list) for users to make selections because none of the default input types for fields were user friendly. These selections update “Global Variable” columns on the user table and then subsequently update my “LOG” table upon submission of the form (subsequent action).

Essentially, i need a way to query the value of the field on my log table/collection for that date/user, and then update the component visual based on that value. Doesn’t seem like that is possible. (in any component outside of standard form components and input types)

Thank you for the help!

 ![PV_VIS](https://us1.discourse-cdn.com/flex020/uploads/adalo/original/3X/9/e/9e8456c5c663756a16c95db55b57c7b416d23f21.png)

---

<div class="post-metadata">

**Author:** ![Michael](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/michael/32/3120_2.png) [@Michael](https://forum.adalo.com/u/Michael)\
**Post date:** [July 8, 2022, 3:53pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/4 "2022-07-08T15:53:24Z")

</div>

Hey @magoo6617  
If you want it to start off highlighted then you just need to have the text in the below field match the text in the chip. (you could save the text in the user’s database and use magic text)

 ![image](https://us1.discourse-cdn.com/flex020/uploads/adalo/original/3X/3/d/3de08a24e7b315b554de8e23db0d9610b1e7f117.png)

So in your case it would actually be “1-Mild”.  
Let me know if you still have a question about this.

---

<div class="post-metadata">

**Author:** ![magoo6617](https://avatars.discourse-cdn.com/v4/letter/m/848f3c/32.png) [@magoo6617](https://forum.adalo.com/u/magoo6617)\
**Post date:** [July 8, 2022, 4:09pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/5 "2022-07-08T16:09:03Z")

</div>

Wow Michael, that was it, thank you. Right in front of me all along.

---

<div class="post-metadata">

**Author:** ![Michael](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/michael/32/3120_2.png) [@Michael](https://forum.adalo.com/u/Michael)\
**Post date:** [July 8, 2022, 4:21pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/6 "2022-07-08T16:21:57Z")

</div>

Haha, no problem. Glad we got it figured out.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/system/32/40401_2.png) [@system](https://forum.adalo.com/u/system)\
**Post date:** [July 18, 2022, 4:21pm UTC](https://forum.adalo.com/t/preset-a-value-selection-based-on-existing-collection-separate-table/29215/7 "2022-07-18T16:21:58Z")

</div>

Closed on July 18, 2022, 4:21pm UTC

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