Hi,
I have a table like this
kit|part
1 | 21
1 | 22
1 | 23
1 | 24
2 | 30
2 | 31
....
Number of related parts to kit can be from 1 to 30
Would like to return this in one row like below
Part would ideally be in 1 column separated by a value like comma
Data Type is Integer for both kit and part
1 | 21,22,23,24
2 | 30,31
I have tried self joins and have tried group concat but have not been successful
What is best way to accomplish this ?
I have a table like this
kit|part
1 | 21
1 | 22
1 | 23
1 | 24
2 | 30
2 | 31
....
Number of related parts to kit can be from 1 to 30
Would like to return this in one row like below
Part would ideally be in 1 column separated by a value like comma
Data Type is Integer for both kit and part
1 | 21,22,23,24
2 | 30,31
I have tried self joins and have tried group concat but have not been successful
What is best way to accomplish this ?