473,978 Members | 2,272 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Putting multipule Dataset tables into one table


Hi,

I have a dataset that has a number of tables in it, each table has only
one column - that column is the same name in each table.

I now want to have all these tables as one table and then loop through
the rows of this one table, and put them into an arraylist.

I was trying to do this using the dataview as I figure this must be the
tool to get all the table rows into one table (see below code).

Any and all help greatly appreciated.

Dim mySqlDataAdapte r As SqlDataAdapter = New SqlDataAdapter( strSql,
myConn)
Dim myDataSet As DataSet = New DataSet
mySqlDataAdapte r.Fill(myDataSe t, "Values")
Dim dv As DataView

Nov 21 '05 #1
1 1362
Kieran,

How did you get the idea that the dataview should be the tool for that the
dataview is a view on *one* table.

When you want to make set all the columns in one arraylist than you have to
create first an object that is confirm the way you want to place that in it.
(a data class) and than loop though that)

In my opinion a lot of work while you can create as alternative to that as
well a new datatable and than loop generic through your dataset.

However probably this will fail. I think that you get the data from more
database tables. That needs something more than I tell now. Otherwise it is
just changing the Select and name all the columns you want.

I hope this helps,

Cor
Nov 21 '05 #2

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

Similar topics

3
3168
by: Alex Ayzin | last post by:
Hi, I have a problem that might be easy to solve(possibly, I've just overlooked an easy solution). Here we go: I have a dataset with 2 datatables in it. Now, I need to do the following: if ds.table(0).rows(0).item("col1") = ds.table(1).rows(0).item("col2") then txtResult.text = ds.table(1).rows(0).item("col3")
1
1853
by: Oxnard | last post by:
One of the issues I seem to run into is text, tables and such being display to the left of some other object. The only way around it I have found is to make one big table and start dividing it up. Below is an example. The second table tends to want to be to the right of the first table. What is another way to prevent tables and such without making a very large table or using frames? Note the <!-- --> are in there as I'm using OE. For some...
3
4627
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, including column names and row values for each column. I'm getting some strange results depending the input XML file I use. I was wondering if somebody could help me understand what is going on or point me to a good reference. The code for my program looks like this:
3
24409
by: Jim | last post by:
I have a stored procedure that queries a sql server database and returns the multiple data tables ( 7 to be precise) these tables are the results of many joins. When I use the System.Data.SqlClient namespace objects to access this data it is returned intoa dataset, this dataset has the tables as expected but they are name 'Table', 'Table1' , 'Table2' etc.... How can I ge the table name to be more friendly as in "Customers", "Rates"...
1
8598
by: Fleckman | last post by:
I have a situation where I need to add rows to tables with a Parent-Child relationship which presents a constraints violation when I reject the changes. Here is the scenario: I add a row to a Parent table which then causes a row to be added to the Child table referencing the parent row. The Child table rows can be modified by multiple processes so I need to manage row additionals separate from row modifications in terms of how they are...
22
4255
by: EMW | last post by:
Hi, I managed to create a SQL server database and a table in it. The table is empty and that brings me to my next chalenge: How can I get the info in the table in the dataset to go in an empty SQL table? Is there a short way like the FILL method to get data into the dataset or do I have to read each datarow in the table and write it one at the time to the
9
13007
by: jaYPee | last post by:
I have search a lot of thread in google newsgroup and read a lot of articles but still i don't know how to update the dataset that has 3 tables. my 3 tables looks like the 3 tables from northwind database that has an employees, orders, and order details. the following are the 3 tables in my sql database students schyrsem
0
327
by: kieran | last post by:
Hi, I have a dataset that has a number of tables in it, each table has only one column - that column is the same name in each table. I now want to have all these tables as one table and then loop through the rows of this one table, and put them into an arraylist. I was trying to do this using the dataview as I figure this must be the tool to get all the table rows into one table (see below code).
3
2286
by: P K | last post by:
Hello, I have a dataset which is already loaded with data in one table. so dataset.tables("data") exists and has data. Now, I have to add another table to the dataset. The source for this table is a XMLDoc. So I have the XML in a XMLDoc and I need to create a table in the dataset which would read xml from the XMLDoc . So in essence I need something like
4
2261
by: Al | last post by:
I have this scenario: 1. XML file with schema and data is created from SQL Server tables. XML file contains 6 tables, some of them have rows, some of them are empty. 2. XML file is given to the person with Pocket PC. 3. XML file is used to populate DataSet on the Pocket PC. 4. User adds new rows, changes values, deletes some rows. 5. Altered dataset is saved back to XML file. 6. XML file is given back to the person who initially created...
0
10359
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10176
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11427
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
11594
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10922
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7621
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
6426
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
4744
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3774
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.