This is what i have so far:
I have no idea which way to go next, basically i have a field called "LOC_ID" that has a bunch of duplicates in it. I need to select one of each variation using the "LOC_ID" field while still keeping all the other fields in the record.
CntTblSQL = "SELECT sorted.LOC_ID, Count(sorted.LOC_ID) AS CountOfLOC_ID INTO CntTable FROM sorted GROUP BY sorted.LOC_ID ORDER BY sorted.LOC_ID;"
pass1 = "SELECT * FROM CntTable"
dataconnect.Open pass1, CurrentProject.Connection, adOpenDynamic, adLockOptimistic
Do While Not dataconnect.EOF
strLocId = dataconnect.Fields("LOC_ID").Value
Count = dataconnect.Fields("CountofLOC_ID").Value
any help would be much appreciated!