1
Answer

convert key value column table to DTO dynamically in c# linq

Photo of siva nathan

siva nathan

4y
1.1k
1
Hi All,
 
I have a key and value pair table in sql server like below,need to convert that table into DTO in linq C#
 
 
 Key value
 Name john
 Address USA
 Name Ken
 Address America
 
am having one DTO like bewlo
Public class SampleDto
{
public string Name { get;set;}
public string Address { get;set;} 
 
need to select that key,value table into List of above class columns key and value column and DTO may be add/delete
how can i achieve that 

Answers (1)