converting query result into an array

1 view
Skip to first unread message

henr...@gmail.com

unread,
Jul 28, 2006, 2:53:44 PM7/28/06
to DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting
I have a query result of 1 column and 20 rows of integers. How Can I
store this result in an array.?
or is there any other method I can use that would allow me to retreive
any single item in the query result anytime in my code
(am working with sql database , asp.net and C#)

Raghuraman_ace

unread,
Jul 29, 2006, 1:13:27 AM7/29/06
to DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting
Hi

just populate the datatable with the query results u want .Then use

datarow a[] ;
a=datatable.select("dummy
condition",sortcol,datarowviewstate.currentrows).The outcome of this
method will be the datarow array .

Hope this helps.

A drop in the oecean of sixfaces.
Raghuraman Tricomp technilogies, India

Reply all
Reply to author
Forward
0 new messages