ROW_NUMBER() equivalent in MySQL for inserting [duplicate]
This question already has an answer here: ROW_NUMBER() in MySQL 23 answers i'm trying to convert SQL scripts that was created in Microsoft SQL Server to run with a link sever to scripts that can be used in SQL Procedures, the script i'm on uses ROW_NUMBER() OVER(ORDER BY [FIELDS]) to create a primary key that isn't dependent on Auto Increment, when i try and save the code as a Procedure i get this error ERROR 1064 (42000): You have an error in your SQL syntax: check the manual that corresponds to your MySQL server version for the right syntax to use near '(ORDER BY [FIELDS])' at line [LINENO]