Free Account MySQL Privilege?

I have a free account in which i am using MySQL in my app (api) to register or login users but i not able to register any user it is not working.

To do so i need these MySQL privilege:

  • SELECT, INSERT, UPDATE, DELETE privileges on following tables: mysql.db, mysql.columns_priv, mysql.tables_priv, mysql.procs_priv
  • FLUSH privilege (GLOBAL)

So i want to ask if these privilege is available in free account or not
or how can i use these privilege (if possible with free account)

I think those may already be enabled. I might be wrong

You can’t change mysql permissions on free, switch to premium if you need that.

Websites can only be accessed by humans on a web browser, there is a security system in place

1 Like
  1. Create mysql database and import database.sql from unzipped package. Follow below steps to create and import database :
  • Under Databases, enter database name(as you want) and click on create button.
  • On the left, select the database that you have just created.
  • Click Import in the top menu.
  • Under File to Import, click Browse and select database.sql file from unzipped package.
  • Click Go at the bottom right to import the database file
  • When the database has been imported successfully, you should see a message at the top of the page similar to: Import has been successfully finished, ## queries executed.
  1. Open the application/config/config.php file with a text editor and set your base URL.

  2. Open the database.php file from root with a text editor and setup your database settings.

  3. And you also need to setup database and URL setting for API. Open api/.env file with a text editor and setup your database settings and set base URL in APP_URL.

You are going to be blocked by this:

InfinityFree is meant for hosting websites, and nothing else. Please read the TOS before using the service.
Thanks

See above.

I believe premium does allow external connections. Alternatively, you can just find a database host.

2 Likes

Please note the difference between “MySQL users” and “users stored in a MySQL database”.

If you want to do authentication in your own application, you probably want “users stored in a MySQL database”. You don’t need any special permissions for this, just basic CRUD on the tables that store the user information for your app.

The permissions you’re asking for are related to “MySQL users”. Which are the users that are allowed to login to the database server. Your application is using a MySQL user to login and access your own database.

You don’t get write permissions to the system tables that store MySQL users. You will never get that on any shared database server, because it basically allows you to insert whatever permissions you want, including stealing other people’s databases.


So to answer your questions:

  • No, you will not get these permissions on free hosting. Or premium hosting. Only on VPS hosting where you can setup your own database.
  • You don’t need these permissions. We don’t allow API hosting and that’s probably why your authentication doesn’t work. This DOES work on premium hosting.
3 Likes

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