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;
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number

Forum statistics

Threads
1,224,823
Messages
6,181,177
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top