I have a view vwGetData which gets data from two tables t1,t2 and has fields:
t1.Field1 [ALIAS1], t1.Field2, t2.Field3, t2.Field4, t2.Field5 [ALIAS5]
I will provide below input
Select * from vwGetData
i want to get below output in C#/SQL
ALIAS1
Field2
Field3
Field4
ALIAS5
or
ALIAS1, Field2, Field3, Field4, ALIAS5
I want to do this using C# and SQL.
The first thing you would do is make sure that no data gets returned:
Now assuming you know how to set up a DataReader you would do the following:
You can also could also look into the SQL Catalog SYS Views.