insert command denied in mysql

后端 未结 7 1247
天涯浪人
天涯浪人 2021-01-17 07:41

I have a database table from which, when I select data with username and password, it works but when I insert some data in that table with same username and password it show

7条回答
  •  忘掉有多难
    2021-01-17 08:16

    I had a similar problem after moving my site from one hosting account to another. The problem was caused by a SQL query (INSERT) that referenced the old database. replacing the old db with the new db name (or just removing the db name altogether) solved the problem. But this mistake stumped the support people at my hosting company.

    Example:

    INSERT INTO old_db_name.table_name ( ) VALUES ();
    

    Changed to:

    INSERT INTO new_db_name.table_name ( ) VALUES ( );
    

    Hope this helps and makes sense.

提交回复
热议问题