Hi, I need a little help trying to select a count of unique records from a select. Currently I'm doing this using DCOUNT :
RCs = DCount("parent_id", "LinkTable", "PARENT_TYPE='RC' AND CHILD_TYPE='SR' AND CHILD_ID In (SELECT child_id FROM LinkTable WHERE parent_id=" & E3 & "
"
This gives me all of the type RC that are linked to the type SR in LinkTable. It works exept for the fact is a M:M relationship and when a single SR is linked to multiple RC's I need the UNIQUE RC's not the total. (This number is used in a calculation of a score rating on the same form). Does anyone have any idea how I could get a count of UNIQUE records from this? Kris McCuller
Programmer Portiva Corp.
kmcculler@portiva.com
RCs = DCount("parent_id", "LinkTable", "PARENT_TYPE='RC' AND CHILD_TYPE='SR' AND CHILD_ID In (SELECT child_id FROM LinkTable WHERE parent_id=" & E3 & "
This gives me all of the type RC that are linked to the type SR in LinkTable. It works exept for the fact is a M:M relationship and when a single SR is linked to multiple RC's I need the UNIQUE RC's not the total. (This number is used in a calculation of a score rating on the same form). Does anyone have any idea how I could get a count of UNIQUE records from this? Kris McCuller
Programmer Portiva Corp.
kmcculler@portiva.com