I have 3 tables with id as common field. In 3rd table I have Lineindex,line columns which has multiple value like following :
Table A:
id name
----------
1 name1
Table B:
id value Aid
-------------
1 val1 1
Table C:
id lineindex line Aid
--------------------------
1 1 lin1 1
2 2 lin2 1
Now, I want to take record by joining these table in a single row like'
a.id name b.id value line1[line+lineindex] line2[line+lineindex]
-------------------------------------------------------------------------
1 name1 1 val1 lin1 lin2
Like, the line values in table- C need to get in single row.
How can we achieve this?
Best Answer
I achieved this by doing the following: