# How to create a new user in pure sql

**URL:** <https://meta.discourse.org/t/how-to-create-a-new-user-in-pure-sql/136525>\
**Category:** Migration\
**Created:** [December 19, 2019, 5:15pm UTC](https://meta.discourse.org/t/how-to-create-a-new-user-in-pure-sql/136525 "2019-12-19T17:15:39Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![michaeld](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/michaeld/32/1594_2.png) [@michaeld](https://meta.discourse.org/u/michaeld)\
**Post date:** [December 19, 2019, 10:39pm UTC](https://meta.discourse.org/t/how-to-create-a-new-user-in-pure-sql/136525/5 "2019-12-19T22:39:32Z")

</div>

> [@paultaylor](#):
>
> connect to my JForum mysql server from my discourse server

How about setting up an SSH tunnel?

> [@pfaffman](#):
>
> a corrupt database

Inconsistent, maybe. Corrupt, no.

> [@paultaylor](#):
>
> want to be able to plugin/method that keep the md5 password hash rather than requiring all users to reset their passwords so I don’t think I can do this using the API

But you can create the users using the API and then insert the md5 hashes in a custom field using SQL. You will have best of both worlds.

---

_[View the full topic](https://meta.discourse.org/t/how-to-create-a-new-user-in-pure-sql/136525)._
