From below table1 I am trying to extract value as shown below in table 2,
Table1
<colgroup><col style="width:48pt" span="8" width="64"> </colgroup><tbody>
</tbody>
Table2
Smith - 'This would be selected based on names available on the table1 data area, its typed mannualy,'
Smith-Class15-Maths1 - 'Smith was the typed value for which it picks first column header and matches with its row valu
Smith-Class16-Science2 - 'Similarly for all available columns these rows will generated
Smith-Class17-Music1
Smith-Class19-Maths1
Smith-Class20-Bio2
Smith-Class21-Maths2
Table1
Subject | Class15 | Class16 | Class17 | Class18 | Class19 | Class20 | Class21 |
Science1 | X | Clarke | X | Andrea | Thomas | ||
Maths2 | Z | Y | Smith | Y | Thomas | Smith | |
Bio2 | Y | Clarke | X | Andrea | Z | Smith | X |
Science2 | Clarke | Smith | Thomas | Thomas | Clarke | X | Y |
Maths1 | Smith | Andrea | Andrea | X | Smith | Y | Z |
Bio1 | Andrea | Thomas | Clarke | Y | Andrea | Z | Clarke |
Music1 | Thomas | Z | Smith | Z | Thomas | Clarke | Andrea |
Piano2 | X | Y |
<colgroup><col style="width:48pt" span="8" width="64"> </colgroup><tbody>
</tbody>
Table2
Smith - 'This would be selected based on names available on the table1 data area, its typed mannualy,'
Smith-Class15-Maths1 - 'Smith was the typed value for which it picks first column header and matches with its row valu
Smith-Class16-Science2 - 'Similarly for all available columns these rows will generated
Smith-Class17-Music1
Smith-Class19-Maths1
Smith-Class20-Bio2
Smith-Class21-Maths2