# Deleting Users in rails console

**URL:** <https://meta.discourse.org/t/deleting-users-in-rails-console/141540>\
**Category:** Product Support\
**Created:** [February 13, 2020, 7:26pm UTC](https://meta.discourse.org/t/deleting-users-in-rails-console/141540 "2020-02-13T19:26:34Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)\
**Post date:** [February 17, 2020, 6:37pm UTC](https://meta.discourse.org/t/deleting-users-in-rails-console/141540/4 "2020-02-17T18:37:18Z")

</div>

OK, so that means the user you’re trying to delete has posts: `PostsExistError`.

The suggested method of resolution here would be to review the users posts, and delete them 1-by-1, in case there are any you wish to keep by changing the user. Remember that deleting the first post in a topic deletes the topic too.

The “just do it” method would be to change `delete_posts: false` to `delete_posts: true`.

---

_[View the full topic](https://meta.discourse.org/t/deleting-users-in-rails-console/141540)._
