Hi,
I have a datatable to store the User ids and Exam score details.
Data table has four columns. Row Id (unique), UserId, Exam Id and Score.
Same user can take the same exam multiple times and can have different scores in each attempt.
I want to fetch rows that have the same user id and exam Id and the score obtained in each attempt.
For example, UserA takes Exam1 four times. Table will have 4 rows with UserA and Exam1. But the score will be different for each attempt.
I want to get the score for all the 4 attempts and get the maximum score out of four.
UserX takes Exam2 ten times. I want to get the score obtained in all the ten attempts by UserX.
How to filter the rows in a table that has same User Id and Exam ID using LINQ? And loop through the rows for each User id?
Thanks
Ashok
I have a datatable to store the User ids and Exam score details.
Data table has four columns. Row Id (unique), UserId, Exam Id and Score.
Same user can take the same exam multiple times and can have different scores in each attempt.
I want to fetch rows that have the same user id and exam Id and the score obtained in each attempt.
For example, UserA takes Exam1 four times. Table will have 4 rows with UserA and Exam1. But the score will be different for each attempt.
I want to get the score for all the 4 attempts and get the maximum score out of four.
UserX takes Exam2 ten times. I want to get the score obtained in all the ten attempts by UserX.
How to filter the rows in a table that has same User Id and Exam ID using LINQ? And loop through the rows for each User id?
Thanks
Ashok