Safe Updates in Phpmyadmin

Asked

Viewed 71 times

2

In Mysql Workbench has a very useful function called: "Safe Updates", which prevents Updates in a column without WHERE, for example.

In Phpmyadmin, is there this function? I could not find.

1 answer

1


You have some options:

  • remove the DELETE and UPDATE permissions from the user accessing Phpmyadmin and create a stored Procedure for these operations (which requires the content of the WHERE clause between its parameters)

  • you can create triggers that give ROLLBACK in the upda te if the number of updated lines is equal to the number of rows in the table (it may go wrong if other users enter records in parallel)

  • you can customize the PHP Myadmin code (which is opened) so that it validates the contents of the query formats and prevents the user from submitting Updates and Deletes without Where, of course, to do this, you need to know the code of the Phpmyadmin and need to be able to include such change without giving in the rest of the functionalities

  • Great, Marcelo Bezerra! Thank you very much!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.