Howto display multiple records grouped
Hi everybody,
For example when i've got 2 tables in my database: chickenGroup and chickenDetails
chickenGroup got 3 rows:
Code:
id groupName
1 Group 1
2 Group 2
3 Group 3
and chickenDetails got 4 rows:
Code:
id groupID chickenName
1 1 Betty
2 1 Joy
3 2 Harry
4 3 Bertha
How can i display this like this
Groupname: [groupName]
Chicken: [chickenName]
and when there are more chickens in the group i want to show more names like
Groupname: [groupName]
Chicken 1: [chickenName],
Chicken 2: [chickenName]
Thanks for the help!