How to Rank this...

  • I'm failing to write a suitable rank function to label the following select resultset as seen here. I want my RankNumber column to be as set out here...

    Untitled

    Basically for each account id, i want to sequentially number the rows from 1 to X and the number needs to change only when the accountowner changes. Each row for each account needs to be ordered in "LastModifiedDate" DESC order first.

     

  • Would you please provide your sample data in the form of CREATE TABLE / INSERT statements?

    The absence of evidence is not evidence of absence.
    Martin Rees

    You can lead a horse to water, but a pencil must be lead.
    Stan Laurel

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply