473,405 Members | 2,338 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,405 software developers and data experts.

how to query a dataset with xml tables inside.

I have two xml docs, authors & articles. Both have authorID as a common node

<?xml version="1.0" encoding="utf-8"?>
<!--This is a comment-->
<Authors>
<Author>
<AuthorID>0</AuthorID>
<Name>Mark</Name>
<Login>mark</Login>
<Pwd>markpwd</Pwd>
</Author>
<Author>
<AuthorID>1</AuthorID>
<Name>Ken</Name>
<Login>ken</Login>
<Pwd>kenpwd</Pwd>
</Author>
</Authors>

<?xml version="1.0" encoding="utf-8"?>
<!--This is a comment-->
<Articles>
<Article>
<ArticleID>0</ArticleID>
<ArticleTitle>The Very First Article</ArticleTitle>
<ArticleBody>Body of first aritcle</ArticleBody>
<AuthorID>0</AuthorID>
</Article>
<Article>
<ArticleID>1</ArticleID>
<ArticleTitle>Second Article</ArticleTitle>
<ArticleBody>Second Body </ArticleBody>
<AuthorID>0</AuthorID>
</Article>
<Article>
<ArticleID>2</ArticleID>
<ArticleTitle>Third Article</ArticleTitle>
<ArticleBody>3333333333333333 Body </ArticleBody>
<AuthorID>1</AuthorID>
</Article>
</Articles>
I put both tables into a dataset, created a datarelation

dsR.Relations.Add("dsRdsU",dsR.Tables["Author"].Columns["AuthorID"],dsR.Tables["Article"].Columns["AuthorID"]);

Question is, how do I set the source of a datagrid to show the AritcleTitle - Name pair?

DGFileList.DataSource = ???
DGFileList.DataBind();

If a dataset is an in-memory database then I should be able to query it somehow. I have not seen any examples on the net.

TIA,
Mark
Nov 12 '05 #1
0 1722

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

Similar topics

3
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...
7
by: Richard Myers | last post by:
Hello. I am getting an InvalidCastException which has revealed yet more of my ignorance. I cant believe i dont already know this and haven't encountered it before until now. I am consuming a...
7
by: Phin | last post by:
I need your HELP! I've seen all the posts on using Crystal Reports within vs.net (vb.net) and changing a SQL query at runtime. When I tried to pass in a dataset into the crystal report at...
1
by: Nedu N | last post by:
Hi All, I am facing problem in copying content of table from a untyped dataset into to a table inside the typed dataset. I wanted to copy the data into typed dataset in order to ease the further...
2
by: Nedu N | last post by:
Hi Techies, I am facing problem in copying content of table from a untyped dataset into to a table inside the typed dataset. I wanted to copy the data into typed dataset in order to ease the...
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 and select the filenames from the join, add to...
3
by: Hyphessobricon | last post by:
Hallo, Indeed, a count of a query with a group by function gives more records than there are and so for-next structures don't function. How is this to be mended. Anyone? Everyone in fact....
4
by: Robert Bravery | last post by:
Hi All, I'm New to VS.net. Trying to figure out this new dataset thingy. Ok so I add a dataadapter with all the correct properties for a table. Then generate the dataset. Now open the dataset and...
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 statement". How do I do this in C#? //I get a vlaue...
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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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
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
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.