Combine Records into one in Access

TyeReece

Board Regular
Joined
Aug 3, 2007
Messages
136
I am trying to run a query that returns two fields,. A name and the county. Of course there are multiple counties so I want to combine those records into one field. I have the following SQL that gives me what I need except for combining all the counties into one field. What needs to be added to this SQL to return one row per name with all the counties associated with that name in one field?

VBA Code:
SELECT PCC_Vendor_Number.FPName, County_List.County
FROM ((PCC_PNum INNER JOIN PCC_Vendor_Number ON PCC_PNum.PCC_VNum = PCC_Vendor_Number.PCC_VNum) INNER JOIN Placements ON PCC_Vendor_Number.PCC_VNum = Placements.PCC_VNum) INNER JOIN County_List ON PCC_PNum.County = County_List.CountyID
WHERE (((PCC_Vendor_Number.PlaceType)=7) AND ((PCC_Vendor_Number.ClosedDate) Is Null) AND ((Placements.datDischarge) Is Null))
GROUP BY PCC_Vendor_Number.FPName, County_List.County
ORDER BY PCC_Vendor_Number.FPName, County_List.County;
 

Some videos you may like

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.

Watch MrExcel Video

Forum statistics

Threads
1,114,116
Messages
5,546,033
Members
410,721
Latest member
adi772
Top