Forums

MySQL "CREATE USER"

Hi.

I'm connecting with my MySQL database using my user and host listed in Databases tab. No problems with that.

But I want to create a new user for that database (the user that I will use to my app connect with the database), but when I tried CREATE USER statement, I got a permission error:

ERROR 1227 (42000): Access denied; you need (at least one of) the CREATE USER privilege(s) for this operation

What I can do to accomplish that?

Thanks in advance.

We don't provide user creation permissions. Your database already has a user for you to use.

Is there a way for me to create a second user with reduced privileges? I would like to create a read-only user for reporting purposes. Thanks! Jenny

Unfortunately not for MySQL -- each PythonAnywhere account only has one MySQL user.

(With Postgres you can create as many users as you like, but I appreciate that may not be very helpful in this case if you already have everything set up with MySQL.)

really?

Serious limitation and security issue. Need to be able to create read only users for databases. Cant do that then this platform is no good for serious use.

Ok. We're sorry that we don't meet your needs.

Hi.

This is exactly what I wanted to do.

Can you consider adding it as a feature.If not wanting to allow arbitrary users to be created, then is it possible to have an automatically created read-only user?

Thanks.

No. For example, you cannot even access PythonAnywhere databases externally without using ssh tunnelling. This would mean that you need to give your PythonAnywhere credentials to them for them to access your database. You can make a webapp endpoint to control access and make it read only.

Hey permalink, it seem that PythonAnywhere has stoped using Mysql, because I would not crate a new DB. I Have attemp to do this from "Databases". Why do they say explicit in your page??.

What happens when you try to create one?

This is in fact a serious limitation and security risk.

In my understanding all the risks can be mitigated in your webapp code