Results 1 to 17 of 17

Thread: [RESOLVED] How to group and rank with reference to another column

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Nov 2017
    Posts
    25

    Resolved [RESOLVED] How to group and rank with reference to another column

    Hello gurus
    I need help in grouping or partitioning and ranking according to the subject. Every subject must have 1st to last student.
    Am using the codes below with vb 2010


    Dim TotaledRecords = From p In db.Assessments
    Where p.Class = cboclass.Text And p.Stream = cbostream.Text
    Select p
    Order By p.Total Descending

    For j = 1 To TotaledRecords.Count
    TotaledRecords.ToList(j - 1).Position = j
    Next
    db.SubmitChanges()

    I want it to restart the ranking with respect to the subject
    thank you
    See attached picture
    Name:  help to code.jpg
Views: 427
Size:  36.0 KB
    Last edited by rickabbam; Nov 7th, 2017 at 11:17 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width