I have a grid table in the front end (PHP on server side), and the master admin can sort data in that grid according to his own wish and save that new sorted order. Once the master admin sorts the data, all the users view data in that order only. And only the master admin has the right to sort and change order.
What I'm doing is, I have an index field (not primary), according to which the data is displayed in ascending order. When the master admin sorts the data and saves that new order, the index field of all the rows in db are reset according to the new order. And for this resetting, I'm running UPDATE queries equal to the number of rows.
Now since there can be lot more then 100 rows, and moreover I don't know much about SQL except SELECT, INSERT and UPDATE queries.
So I was just if there is any other way to do this, so that I need not to run so much queries?
PS: Is it recommended to run around 200 UPDATE queries at a time?