Sorry for the lack of information in my previous post, as I was just trying to get a start on the direction I needed to head. Here is a more comprehensive look at the data set I have now, which I got by combining a few queries I did:
SSN Gruop_ID Group_Name Entity_ID Entity_Name Record_Type Record_Number
### 111 Group1 1 Entity1 special record 00000001
### 111 Group1 1 Entity1 other record null
### 111 Group1 1 Entity1 other record null
### 111 Group1 1 Entity1 other record null
### 111 Group1 2 Entity2 other record null
### 111 Group1 2 Entity2 special record 00000002
### 111 Group1 3 Entity3 other record null
### 111 Group1 3 Entity3 other record null
### 111 Group1 4 Entity4 other record null
### 111 Group1 4 Entity4 other record null
### 111 Group1 5 Entity5 other record null
To give a little more overview. There are thousands of lines just like this with hundreds of groups with different entities. The null values in record_number are not actually null. I just have them showing null if it is a different record than the "special record", which I did with an IIf-Then statement. So what I am trying to sree at this point is can I remove the duplicate entity names. For instance in Group1, their is 1 special record and three other records. I want to show the entity name only once for the special record and omit the duplicates for that same entity name with "other records". As you can see Entities 3, 4 and 5 do not contain a "special record but do belong to Group1. I also want to show each entity name that contain No "special record" once. So the data set above would look like this:
SSN Gruop_ID Group_Name Entity_ID Entity_Name Record_Type Record_Number
### 111 Group1 1 Entity1 special record 00000001
### 111 Group1 2 Entity2 special record 00000002
### 111 Group1 3 Entity3 other record null
### 111 Group1 4 Entity4 other record null
### 111 Group1 5 Entity5 other record null
If I did: IIf([Record_Type]="special record", [Record_Type],Null. This would eliminate entity names for entities that do no have a special record, which is not what I want. I want to show each entity name once. If the entity name had two special records then of course it would have to show twice in order to show both special records, which is fine. Is this possible? Either way thanks again for your help!