0

I would like to map a datatable column names from another datatable. Please refer below example. I have 2 datatables returned from database.

enter image description here

enter image description here

Please see above 2 tables. The first table contains data and second datatable contains column mapping. I would like to map column names from second table to first table. The final result should be as below.

enter image description here

Machindra
  • 57
  • 5

1 Answers1

0

You can generate a SQL statement dynamically and end up with:

Select column1 as city, column2 as country,
column3 as population, column4 as tourist
from whatever_table
Tarik
  • 10,810
  • 2
  • 26
  • 40