Re: Finding a record's position when sorted
SQL Server has a Row_Number() func. MySQL does not. You can create one in a temp table eg
SET @ord=0;
CREATE TABLE temp
SELECT @ord:=@ord+1 AS ord, ...
FROM tbl
ORDER BY ...;
Then join to the temp table in your reproting query.
PB
Subject
Written By
Posted
November 14, 2006 03:39PM
November 14, 2006 05:01PM
November 14, 2006 06:01PM
Re: Finding a record's position when sorted
November 14, 2006 09:56PM
November 14, 2006 11:33PM
November 15, 2006 03:21AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.