# Is there a way to retroactively update trust level and title for existing group members?

**URL:** https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640
**Category:** Support
**Created:** [May 3, 2016, 9:35pm UTC](https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640 "2016-05-03T21:35:18Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [May 3, 2016, 9:35pm UTC](https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640/1 "2016-05-03T21:35:18Z")

</div>

I have a group of 70+ trusted members who I’d like to give TL1 privileges and a title. I see it’s possible to set it up to set the trust level and title for new members as they are added to the group, but this does not appear to affect existing group members. Is there a way to retroactively process these members?

I’d be grateful for any guidance. 🌱

Below is how the group is set up now.

 ![](https://global.discourse-cdn.com/meta/original/3X/e/d/ede8f2c3f7a5a61f63cb2b5c6e6e4278abe0bf75.png)

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [May 4, 2016, 9:10am UTC](https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640/2 "2016-05-04T09:10:16Z")

</div>

> [@tobiaseigen](#):
>
> Is there a way to retroactively process these members?

The only way is to use the rails console. You will need the `id` of the group.

```plaintext
cd /var/discourse
./launcher enter app
rails c
user_ids = GroupUser.where(group_id: <group_id>).pluck(:user_id)
User.where(id: user_ids).where("LENGTH(COALESCE(title, '')) = 0").update_all(title: "awesome title")
User.where(id: user_ids).where(trust_level: TrustLevel[0]).update_all(trust_level: TrustLevel[1])

```

---

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [May 4, 2016, 3:53pm UTC](https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640/3 "2016-05-04T15:53:51Z")

</div>

cool! thanks much. I tried this and it appears to have worked without a hitch! w00t! 🚀

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [December 13, 2018, 7:48pm UTC](https://meta.discourse.org/t/is-there-a-way-to-retroactively-update-trust-level-and-title-for-existing-group-members/43640/4 "2018-12-13T19:48:23Z")

</div>

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