Please peruse the following Query:
SELECT @rownum:=@rownum+1 as rownum, employee_name from (SELECT @rownum:=0) r, employees
This query is used in MySQL to derive ROWNUMBERS (as done in case of Oracle)
My query is that... how can one use this query to create a VIEW in MySQL... when MySQL returns "VARIABLE inside View" error?
Any alternate method of availing ROWNUM in MySQL Views itself?
Thanks in advance.