hi all im using this code, and it is working very fine and my reports shows the expected result
Code:
If cmb.ListIndex = 1 Then
Set rs = con.Execute("select marks from StuMarks where srollno=21")
Set DataReport1.DataSource = rs
DataReport1.Show
End If
but i have to change the to this one
Code:
Set rs = con.Execute("select MAX(marks) from StuMarks where srollno=21")
this is not working i get an error when report opens.

Data field 'marks' not found

but same SQL works without MAX function

please solve this