I have a GridView that I manuall added Bound Columns to the columns are:
Manager Name with Datafield "EMPLNM"
Manager ID with DataField "EMPLID"
Employee Name with DataField "EMPLNM"
Employee ID with DataField "EMPLID"
I have a datatable that is connected to a stored proc call GetEmployees(name) the way I think this should work is
I get a datatable of all the managers first
Next I iterate through that datatable and call GetEmployees for each manager in the first datatable
Then I want a result of the following...
Manager Name Manager ID Employee Name Employee ID
Nick 1234 Jack 12
Nick 1234 Jerry 34
Nick 1234 John 45
Jeff 3456 Frank 56
Jeff 3456 Larry 78
Amy 5678 Curly 00
Amy 5678 Moe 18
Jane 6789 Sam 96
Can someone give me some code to accomplish this? I am unsure what to do here. Also is there a better way to go about this (i.e. come up with another stored proc to get all the data at once somehow). I have a dataAccess class so I do not want to use sqldatasource controls. GetEmployee function returns a datatable can someone help me write out this code? Thatnks in advance.