Quote:
quote:Originally posted by mat41
You can not refer to a recordset in the way you have, you need to assign it to an array using getRows like:
objRS.Open strSQL, objConn
myArray = objRS.getRows()
Have a look on the net about the getRows part of the above code
Wind is your friend
Matt
|
Thanks for the tip Matt.
I managed to use the GetRows thing to get the unique values into an array.
I now need to get a count of how many times the values occur (in the same table).
Is there an easy way of doing this? I could just select the column and order it by "op" which would look something like this:
101
101
101
302
302
603
603 etc etc
I previously thought I would need a list of the unique values (hence the SELECT DISTINCT above) and then loop though a recordset and count the occurances however I am not getting very far..
Is there a better way of achieving this?
I have not bothered to include my pitiful attempts at coding this problem as I was hoping someone could point me in the right direction.
It's not that complicated is it?
Cheers Guys.