472,342 Members | 1,747 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,342 software developers and data experts.

Query dataset/datatable

I have a dataset with an unknown amount of fields. The user can choose a
nuber of numeric fields in that datatable. I am making a chart out of those
fields. I need to know the minimum and maximun values of the highest value
of the selected fields. Is there a way to query that dataset/datatable to
get these values. If so, can you give me an example?

--
Dave
Nov 19 '05 #1
3 5092
I suppose you want to know count of columns in data table:
dataTbl.Columns.Count

Elton

el********@hotmail.com
-----Original Message-----
I have a dataset with an unknown amount of fields. The user can choose anuber of numeric fields in that datatable. I am making a chart out of thosefields. I need to know the minimum and maximun values of the highest valueof the selected fields. Is there a way to query that dataset/datatable toget these values. If so, can you give me an example?

--
Dave
.

Nov 19 '05 #2
No. example....

col1 col2 col3 col4 col5
5 8 9 1 1
6 7 4 20 8
23 33 9 5 9
The user wants to see col1 , col2, and col4 in a one chart. I need to know
the max and min value between those 3 columns. So the minimum value of all 3
columns combined is 1 and the maximum value is 33
--
Dave

"Elton Wang" <an*******@discussions.microsoft.com> wrote in message
news:08****************************@phx.gbl...
I suppose you want to know count of columns in data table:
dataTbl.Columns.Count

Elton

el********@hotmail.com
-----Original Message-----
I have a dataset with an unknown amount of fields. The

user can choose a
nuber of numeric fields in that datatable. I am making a

chart out of those
fields. I need to know the minimum and maximun values of

the highest value
of the selected fields. Is there a way to query that

dataset/datatable to
get these values. If so, can you give me an example?

--
Dave
.

Nov 19 '05 #3
In that case you can use
table.Compute("Max(columnName)","");
and
table.Compute("Min(columnName)","");
find out max value and min value for each column, then
compare them.

Elton

-----Original Message-----
No. example....

col1 col2 col3 col4 col5
5 8 9 1 1
6 7 4 20 8
23 33 9 5 9
The user wants to see col1 , col2, and col4 in a one chart. I need to knowthe max and min value between those 3 columns. So the minimum value of all 3columns combined is 1 and the maximum value is 33
--
Dave

"Elton Wang" <an*******@discussions.microsoft.com> wrote in messagenews:08****************************@phx.gbl...
I suppose you want to know count of columns in data table: dataTbl.Columns.Count

Elton

el********@hotmail.com
>-----Original Message-----
>I have a dataset with an unknown amount of fields. The

user can choose a
>nuber of numeric fields in that datatable. I am making
a chart out of those
>fields. I need to know the minimum and maximun values
of the highest value
>of the selected fields. Is there a way to query that

dataset/datatable to
>get these values. If so, can you give me an example?
>
>--
>
>
>Dave
>
>
>.
>

.

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Job Lot | last post by:
I have written 6 Queries in an Access DB, which are executed in a For Each…Next loop to populate DataSet object. A new DataTable object is created...
3
by: Bill C. | last post by:
Hi, I've got a simple console app that just reads an XML file into a DataSet then prints out a description of each table in the DataSet,...
6
by: goodstart123 | last post by:
For example, the following code works fine without SqlConnection. Any Answer to the question? string connectionString = "server=YourServer;...
4
by: Jim in Arizona | last post by:
Continuing my lessons out of a book, I ran into a problem when trying for the first time to update a datastore (access database in this case). My...
1
by: cindy | last post by:
Get data into datatable, add to dataset dsSearch " Get data into datatable, add to dataset dsSearch Using In-Memory SQL Engine join the tables...
1
by: Chris Thunell | last post by:
I have a dataset / datatable in memory and i would like to run a query against that to create another in memory datatable or dataview. In this...
8
by: Jim in Arizona | last post by:
I've been using an example out of a book to be able to edit the rows in a database. I am getting the following error: ...
2
by: =?Utf-8?B?Q2hyaXM=?= | last post by:
How can I run this query against a table in my Access database? I don't know hwo to use it in C#. In VB I would use .Recordset = "some sql...
3
by: Oenone | last post by:
I have a project that creates a SqlDataAdapter and uses its Fill method to fill a DataTable with data from a user-provided query. From there I can...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.