473,395 Members | 2,468 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

How to SELECT FROM In-Memory dataset in C# .NET?

Experts:

I have built an in-memory dataset by parsing a flat file so that I can
display the contents onto a datagrid.

The Microsoft C# .NET System.Data.DataTable.Select() method allows me
to select all rows that meet certain criteria (just like "WHERE") and
to sort them (just like "ORDER BY").

I want to perform more analysis on this in-memory dataset such as
SUM(), COUNT(*), MIN(), MAX() and possibly even JOIN.

There has to be a way to do SQL commands 100% in-memory without writing
this dataset to a database server. We already have the data in a
dataset in-memory. How can we then use the power of SQL or C# to
process the data further?

Thank you.

Apr 28 '06 #1
3 20800
I think you have a compute() function for that.
--


"Bi**********@gmail.com" wrote:
Experts:

I have built an in-memory dataset by parsing a flat file so that I can
display the contents onto a datagrid.

The Microsoft C# .NET System.Data.DataTable.Select() method allows me
to select all rows that meet certain criteria (just like "WHERE") and
to sort them (just like "ORDER BY").

I want to perform more analysis on this in-memory dataset such as
SUM(), COUNT(*), MIN(), MAX() and possibly even JOIN.

There has to be a way to do SQL commands 100% in-memory without writing
this dataset to a database server. We already have the data in a
dataset in-memory. How can we then use the power of SQL or C# to
process the data further?

Thank you.

Apr 28 '06 #2
Bill,
The Microsoft C# .NET System.Data.DataTable.Select() method allows me
to select all rows that meet certain criteria (just like "WHERE") and
to sort them (just like "ORDER BY").

I want to perform more analysis on this in-memory dataset such as
SUM(), COUNT(*), MIN(), MAX() and possibly even JOIN.


According MSDN all this is supported by the select methods. For more details
see:
http://msdn.microsoft.com/library/de...ssiontopic.asp
--

Stoitcho Goutsev (100)
Apr 28 '06 #3
Stoicho:

Thank you for the link; however, it still does not answer how I can
SUM() across all rows.

I would like to create a view, a column, whatever to SUM() or AVG() or
MIN() or MAX() across all rows of a table in memory.

Any clues or hints?

Apr 28 '06 #4

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

Similar topics

0
by: dregier | last post by:
attached is my full query that I am currently working on: Declare @counterday1 int Declare @counterday2 int set @counterday1 = '20' set @counterday2 = '629' Declare @CounterMin07_01 float...
1
by: joealonso | last post by:
Problem: I have an xml news feed: blah blah yesterday by the news from General Motors (NYSE:GM) that helped bring the market to a three-week high blah blah We all know that the old days are...
4
by: celerystick | last post by:
This is an xsl question, comp.infosystems.www.authoring.stylesheets were not able to help , here goes .... With one xml file containing repeated element <subject>: ...
3
by: gekoblu | last post by:
Hi!, I want to fix via javascript the combo width to a fix value. I'd like to implement a kind of ALT / TITLE function to show the entire option when the text is longer than the combo width......
3
by: Rick | last post by:
Is there a way to select all the elements of a list via a JavaScript? This is a way it is <form action="" method="post" enctype="application/x-www-form-urlencoded"> <select name="select"...
6
by: Sjaakie | last post by:
Hi there, I'm trying to get this working with Firefox. Can you point out what's wrong? No problems with IE, Firefox doens't fill selMonth... TIA >>> the script... >>> <select name="selDay"...
3
by: Ker | last post by:
I have a query that works great. It gives me the min for multiple fields. Within this query, I also need to get the max of some fields too. I currently have output of Date Name ...
3
by: Randall Skelton | last post by:
I have a number of tables with the general structure: Column | Type | Modifiers -----------+--------------------------+----------- timestamp | timestamp with time zone |...
7
chunk1978
by: chunk1978 | last post by:
hello. so i have 2 select menus which add and remove options from a 3rd select menu... it seems, however, that it's not possible to use different select menus to toggle a 3rd, because when an...
3
by: Italio Novuas | last post by:
Hi all, let me begin by saying that I *ALMOST* have this complete! What I'm trying to do is make it so my text area shows the innerHTML of any select item with the same value. For example, if I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.