473,396 Members | 1,996 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,396 software developers and data experts.

Query a DataSet Table in Visual Studio 2005

Hi all

I have a Dataset name: dsMain

I popullate with all the data from the database on form load event

I have a requirement to filter data as per users requirement on a button click event

What I want is that when the user clicks the button the program should query the Dataset table and not the database table and return the result

So basicly I want to know how can I use T-SQL statements on a Dataset table and get result.

If somebody can help me out with this and provide some examples of this will be of great help.

Regards,
Mayank
Jan 9 '07 #1
2 2710
MaybTank,

A dataset is not an SQL type database. It is a set of tables and relations.

You can however query it with the inbuild DataTable Select which has its own
query expression language, however that is not T-SQL. Beside that there is
the dataview for filtering and sorting.

In future there will be LINQ to improve that Expression language, which is
at the moment very poor.

Cor
<fo*********@yahoo.comschreef in bericht
news:eg**************@TK2MSFTNGP04.phx.gbl...
Hi all

I have a Dataset name: dsMain

I popullate with all the data from the database on form load event

I have a requirement to filter data as per users requirement on a button
click event

What I want is that when the user clicks the button the program should
query the Dataset table and not the database table and return the result

So basicly I want to know how can I use T-SQL statements on a Dataset
table and get result.

If somebody can help me out with this and provide some examples of this
will be of great help.

Regards,
Mayank

Jan 9 '07 #2
What are you trying to accomplish? Are you just wanting to let the
user filter the displayed data? You can do this by binding the
data to the grid or whatever control you are using. Use a
binding source between the data source and the control(s).
Then if you apply the filter to the binding source, it will
filter the dataset entries available to the control(s).

Robin S.
-------------------------------------------
<fo*********@yahoo.comwrote in message
news:eg**************@TK2MSFTNGP04.phx.gbl...
Hi all

I have a Dataset name: dsMain

I popullate with all the data from the database on form load event

I have a requirement to filter data as per users requirement on a
button click event

What I want is that when the user clicks the button the program should
query the Dataset table and not the database table and return the
result

So basicly I want to know how can I use T-SQL statements on a Dataset
table and get result.

If somebody can help me out with this and provide some examples of
this will be of great help.

Regards,
Mayank

Jan 9 '07 #3

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

Similar topics

5
by: Jo ARild | last post by:
I currently have a web-application which on last framework called a serviced component with a dataset. 'ds.RemotingFormat = SerializationFormat.binary ‘ds.RemotingFormat =...
0
by: fonnylasmana | last post by:
Hi, I am new in ASP.Net. I used 2 ways of coding to get the same result. The first one is by typing all the codes directly to the asp.net page and it works. The code looks like this: <%@...
5
by: Monty M. | last post by:
Hello; I was wondering if anyone can assist me with this problem. Here are the tools I am using: Language: C# Database: MS SQL Server 2000 Application: Visual Studio 2005 1. I have a...
19
by: Dave | last post by:
If Iwant to check if dataset1.SelectQuery1.column1 == System.DBNull.Value. How do I do this? What I wrote above will give an error. -- L. A. Jones
5
by: xarky1984 | last post by:
Hi, I am using Visual Studio 2005 and has a problem with DataSet Designer. While I was using Visual Studio, 'A Package Load Failure Error' was given. Visual Studio terminated and when...
0
by: forforumsid | last post by:
Hi all I have a Dataset name: dsMain I popullate with all the data from the database on form load event I have a requirement to filter data as per users requirement on a button click event ...
0
by: CheshireCat | last post by:
I have added an access database into my 2005 desktop project, created a dataset called ResourcesDataSet which contains one of each table in the database using the wizard. The database was...
0
by: =?Utf-8?B?cmFuZHkxMjAw?= | last post by:
I'm working in Visual Studio 2005 Team Edition for Software Developers. I have 3 tables defined in the DataSet Designer, and a DataRelation between each table. The user sees a each of these...
7
by: kunku | last post by:
Hi, I am using a query "Select SUM(Amount) from tblAccount where TransactionID=' "+textBox1.Text+" ' "; in my C# project this query return dataset.Tables.Rows.Count =1 eventhough there...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.