# Cannot delete or rename user

**URL:** https://meta.discourse.org/t/cannot-delete-or-rename-user/40221
**Category:** Bug
**Created:** [February 26, 2016, 11:25am UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221 "2016-02-26T11:25:14Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![RalfJung](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ralfjung/32/51654_2.png) [@RalfJung](https://meta.discourse.org/u/RalfJung)
#### Post date: [February 26, 2016, 11:25am UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221/1 "2016-02-26T11:25:14Z")

</div>

I have two users in my system that were just recently, accidentally created and block their usernames. I would like to delete them, or at least rename them, so that “real” users can get their names.

So I go to the user page in the admin interface, and I press “Delete User”. However, now Discourse complains it cannot delete the user and I should check for posts. Well, these users never posted, and their post count on the same page is 0. How can I delete these users?

I also tried renaming the user, by pressing “Rename User”. However, then I end up on `/404`.

This is with a Discourse just re-built this morning, `version: stable`, version 1.4.6.

---

<div class="post-metadata">

### Author: ![RalfJung](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ralfjung/32/51654_2.png) [@RalfJung](https://meta.discourse.org/u/RalfJung)
#### Post date: [February 26, 2016, 11:31am UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221/2 "2016-02-26T11:31:17Z")

</div>

I am seeing this error in the logs:

```plaintext
PG::UndefinedTable: ERROR: relation "group_managers" does not exist
LINE 5: WHERE a.attrelid = '"group_managers"'::regcla...
                                          ^
: SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod
                FROM pg_attribute a LEFT JOIN pg_attrdef d
                  ON a.attrelid = d.adrelid AND a.attnum = d.adnum
               WHERE a.attrelid = '"group_managers"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

```

I guess that’s related?

---

<div class="post-metadata">

### Author: ![RalfJung](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ralfjung/32/51654_2.png) [@RalfJung](https://meta.discourse.org/u/RalfJung)
#### Post date: [February 26, 2016, 11:49am UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221/3 "2016-02-26T11:49:53Z")

</div>

Both of these issues were fixed by updating to version `v1.5.0.beta11`. Whatever…

---

<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: [February 26, 2016, 12:18pm UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221/4 "2016-02-26T12:18:17Z")

</div>



---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [February 27, 2016, 12:45am UTC](https://meta.discourse.org/t/cannot-delete-or-rename-user/40221/5 "2016-02-27T00:45:19Z")

</div>

Sorry about that! 🐛s happen! 😑
