Suppose I have a table MYtable as given below:
ID A B C
1 100 APPLE CAKE
2 200 BANANA PIE
I want to be able to save all these table records into a list (of some kind) and iterate through each record.
Query would be :
select * from Mytable where ID in (1,2,3)
So,the list should have 2 records:
record1 should contain 1,100,APPLE,CAKE
and record2 should contain 2,200,BANANA,PIE
I also want to be able to iterate through each record
So for record1 – I want to getColumnA i.e 100, getColumnB i.e APPLE, and so on
1 Answer