RowNumber function Problem

  • Hi there

    with the RowNumber function we can index table rows for example:

    we have employee table where group1=country,group2=city and group3=employee name:

    USA

         New York

                     1.John Due

                     2.George Gush

         Los Angeles

                     1.Bill Milton

                     2.Roland Begin

    Here is the problem-the RowNumber refer to the last group,but how can i do this:

    USA

         1.New York

                     1.John Due

                     2.George Gush

         2.Los Angeles

                     1.Bill Milton

                     2.Roland Begin

  • I have run into problems with RowNumber before. Sometimes the best way to index rows is with RunningValue()

    I didn't test this at all, but I'm thinking something like:

    RunningValue ( Fields!Group1Something.Value , CountDistinct, "Group1_Name") & ") Fields!Group1Something.Value"

    RunningValue ( Fields!Group2Something.Value , CountDistinct, "Group2_Name") & ". Fields!Group2Something.Value"

    The real trick is using the right Scope.

  • Well,I test it and the correct format is:

    RunningValue ( Fields!Group2Something.Value , CountDistinct, "Group1_Name") & ". Fields!Group2Something.Value"

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

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