I have three tables which I have to join. I'm not a good sql writer. Can please sombody help me to prepare this using joins,
branches
branch_id | branch_name | branch_address
1 name1 address1
branch_services
bs_id | branch_id | service_id
1 1 1
2 1 2
3 1 4
services
service_id | service_name
1 service1
2 service2
3 service3
4 service4
I need to select * from branches table and service_names related to each branch like this
Result
1 | name1 | address1 | service1 service2 service4 |
While i'm searching found something call group_concat.It works. But how to use it with CI???