473,396 Members | 1,725 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.

convert dataset to datatable?

how do i convert dataset to datatable?
this is a sample of a dataset:

Expand|Select|Wrap|Line Numbers
  1. Dim dt As New DataTable
  2. daTicket = New SqlDataAdapter(sql, Connect)
  3. daTicket.Fill(dset, "EmployeeTicket")
  4. dt = dataset.Tables("EmployeeTicket")
  5.  
i appreciate your help
Aug 6 '07 #1
2 29281
kenobewan
4,871 Expert 4TB
Why don't you just create the datatable from a datareader rather than using a dataset? More efficient.This article may help:
Contrasting the ADO.NET DataReader and DataSet
Aug 6 '07 #2
Plater
7,872 Expert 4TB
A DataReader can also fill a DataTable object.

OR

You can use like myDataSet.Tables[0] to get the DataTable
Aug 6 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: DaveF | last post by:
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...
10
by: Bernie Yaeger | last post by:
I have a need to add a primary key to a dataset/datatable. How can this be done using a standard oledb data provider? Tx for any help.
1
by: abc my vclass | last post by:
Is VS2005 debugger let me to see dataset, datatable data as table form? I found if I watch some table or dataset variable is very very hard to see. Is there any good tools or add-ins for debugger...
0
by: AboutJAV | last post by:
Hi, I added a datagrid. When the user make changes to the cells, the datatable was updated with the new values. I need to update the dataset.datatable with the current datatable, but an error...
2
by: Mr. Arnold | last post by:
I am working a C# project that uses what's in the subject. I kind of have the basics down on reading the table data. I don't use the above methods of data access or persistence, but I am stuck...
1
by: Daniel Jeffrey | last post by:
..Net 2.0 VStudio 2005 C# I know this is going to seem like a strange question, as even I am sure I have missed something - but I cant find it. I want a simple event on any of the objects...
1
nev
by: nev | last post by:
dataset.datatable.adddatatablerow("john", "rambo") datatabletableadapter.update(dataset.datatable) when i view my mysql table using navicat, the row was not added. i tried adding...
3
by: ASPnewb1 | last post by:
I am currently filling a dataTable then adding this table to a dataset, setting the dataset to the Gridview's datasource. If I set the Gridview to generate columns automatically it will fill the...
4
by: =?Utf-8?B?RnJhbmsgVXJheQ==?= | last post by:
Hi all I have a DataSet with one table filled. From this DataSet (DataTable), I need to create a SqlDataReader. Does anybody knows how to do this ? Is it possible ?? Thanks for any help.
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:
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...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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.