I've got a db like this:
Accounts
--------
id
BankName
AcctNumber
Balance
AccountGroups
-------------
id
GroupName
JoinAccountsGroups
------------------
aid
gid
I'm trying to generate data like this:
Bank AcctNum Balance Groups
--------|--------------|----------|----------------
Citi 930938 400 Payroll
B of A 8372933 100 Monthly, Payroll
Wells 09837 800 -
Chase 8730923 250 Monthly
Is there an easy way of generating that Groups column in a sql query, that will combine the results of the join into a comma-separated field? I'm currently doing it on the php side using a secondary query on each row as I'm processing it. It's fine for a small dataset, but it seems pretty inefficient...
I'm using php > jet > ms access .mdb file.