Please help me, I am new in this field trying to understand how to achieve updating a column from table with Numbering of each row from that table. (from 1 to ~).
Table name PRODUCTS.
Column name NUMBER.
I want to mention from that the start that Field Number is totally different from the ID. Products are inserting and deleting and ID is autoincrementing. But Field Number is UPDATING with the number of rows. So I want to achieve to have a button while submiting to update the field Number with corespondent number of rows.
Please suggest some MySql script which could help me to update the Field NUMBER with numbers. I would much appreciate any of your suggestion. Thank you in advance!
Something should be in my opinon i=0 and then i++
edited: Database now:
ID NAME NUMBER ________________ 201 Apple 3 203 Orange 5 should be after updating:
ID NAME NUMBER ________________ 201 Apple 1 203 Orange 2