(I posted this in ADO group, but I think this group will be better)
Hi-
I need to develop an FAQ section for our website. We would like to break up
the FAQ by products, then categories with each category having n
question/answer pairs.
I would like to pass parameters in the querystring based on what the
product/category the user selected, then populate a datagrid with the
correct set of question/answer
I am pretty new to XML, but basically I made something like this:
<products>
<product>
<name>prod1</name>
<partNum>prod1</partNum>
<categories>
<category>
<name>basic category</name>
<faqs>
<faq>
<question>This is a sample question</question>
<answer>this is the answer</answer>
</faq>
</faqs>
</category>
</categories>
</product>
<product>
<name>prod2</name>
<partNum>prod2</partNum>
<categories>
<category>
<name>basic something or something category</name>
<faqs>
<faq>
<question>This is another question</question>
<answer>and this is another answer</answer>
</faq>
</faqs>
</category>
</categories>
</product>
</products>
So, then I use a DataSet and the ReadXML() method, this result in 5 tables.
I was hoping that it would somehow be nested for me, but the way it is right
now I can't see an easy way to use it the way I want.
the first table lists the products(good)
the second table I can't really tell what is in there
third tables has all the categories, so on and so on.
What is confusing is... what is the point of structuring data hierarchically
in XML file if you can't maintain it? I'm sure you can, but how? Is what
I'm doing not common?
Someone please shed a little light on this for me, I would appreciate it!!
Thanks,
Steve 4 1630
Create a dataset with datarelations between the tables you want
nested. Set the Nested property prior to writing the xml:
ds.Relations["relationName"].Nested = true;
-- Mary
MCW Technologies http://www.mcwtech.com
On Thu, 4 Dec 2003 16:44:58 -0800, "Steve Klett"
<sk************@yahoo.com> wrote: (I posted this in ADO group, but I think this group will be better)
Hi-
I need to develop an FAQ section for our website. We would like to break up the FAQ by products, then categories with each category having n question/answer pairs. I would like to pass parameters in the querystring based on what the product/category the user selected, then populate a datagrid with the correct set of question/answer
I am pretty new to XML, but basically I made something like this: <products> <product> <name>prod1</name> <partNum>prod1</partNum> <categories> <category> <name>basic category</name> <faqs> <faq> <question>This is a sample question</question> <answer>this is the answer</answer> </faq> </faqs> </category> </categories> </product> <product> <name>prod2</name> <partNum>prod2</partNum> <categories> <category> <name>basic something or something category</name> <faqs> <faq> <question>This is another question</question> <answer>and this is another answer</answer> </faq> </faqs> </category> </categories> </product> </products> So, then I use a DataSet and the ReadXML() method, this result in 5 tables. I was hoping that it would somehow be nested for me, but the way it is right now I can't see an easy way to use it the way I want.
the first table lists the products(good) the second table I can't really tell what is in there third tables has all the categories, so on and so on.
What is confusing is... what is the point of structuring data hierarchically in XML file if you can't maintain it? I'm sure you can, but how? Is what I'm doing not common?
Someone please shed a little light on this for me, I would appreciate it!!
Thanks, Steve
Hi Mary, thanks for the response.
So I would setup the relationions prior to reading teh XML, correct? Have
you ever seen any examples of this?
Thanks again,
Steve
"Mary Chipman" <mc***@nomail.please> wrote in message
news:qh********************************@4ax.com... Create a dataset with datarelations between the tables you want nested. Set the Nested property prior to writing the xml:
ds.Relations["relationName"].Nested = true;
-- Mary MCW Technologies http://www.mcwtech.com
On Thu, 4 Dec 2003 16:44:58 -0800, "Steve Klett" <sk************@yahoo.com> wrote:
(I posted this in ADO group, but I think this group will be better)
Hi-
I need to develop an FAQ section for our website. We would like to break
upthe FAQ by products, then categories with each category having n question/answer pairs. I would like to pass parameters in the querystring based on what the product/category the user selected, then populate a datagrid with the correct set of question/answer
I am pretty new to XML, but basically I made something like this: <products> <product> <name>prod1</name> <partNum>prod1</partNum> <categories> <category> <name>basic category</name> <faqs> <faq> <question>This is a sample question</question> <answer>this is the answer</answer> </faq> </faqs> </category> </categories> </product> <product> <name>prod2</name> <partNum>prod2</partNum> <categories> <category> <name>basic something or something category</name> <faqs> <faq> <question>This is another question</question> <answer>and this is another answer</answer> </faq> </faqs> </category> </categories> </product> </products> So, then I use a DataSet and the ReadXML() method, this result in 5
tables.I was hoping that it would somehow be nested for me, but the way it is
rightnow I can't see an easy way to use it the way I want.
the first table lists the products(good) the second table I can't really tell what is in there third tables has all the categories, so on and so on.
What is confusing is... what is the point of structuring data
hierarchicallyin XML file if you can't maintain it? I'm sure you can, but how? Is
whatI'm doing not common?
Someone please shed a little light on this for me, I would appreciate
it!! Thanks, Steve
Once you add the data to a dataset you can then set the DataRelations
between the different DataTables. There's examples in online help --
see the topic "Adding a Relationship between Tables". Gotdotnet.com
probably has other examples or tutorials as well. Then once you've set
up the relations, you can then set the nested property to true.
-- Mary
MCW Technologies http://www.mcwtech.com
On Mon, 8 Dec 2003 09:53:32 -0800, "neverstill"
<sk************@yahoo.com> wrote: Hi Mary, thanks for the response.
So I would setup the relationions prior to reading teh XML, correct? Have you ever seen any examples of this?
Thanks again, Steve
"Mary Chipman" <mc***@nomail.please> wrote in message news:qh********************************@4ax.com.. . Create a dataset with datarelations between the tables you want nested. Set the Nested property prior to writing the xml:
ds.Relations["relationName"].Nested = true;
-- Mary MCW Technologies http://www.mcwtech.com
On Thu, 4 Dec 2003 16:44:58 -0800, "Steve Klett" <sk************@yahoo.com> wrote:
>(I posted this in ADO group, but I think this group will be better) > >Hi- > >I need to develop an FAQ section for our website. We would like to breakup >the FAQ by products, then categories with each category having n >question/answer pairs. >I would like to pass parameters in the querystring based on what the >product/category the user selected, then populate a datagrid with the >correct set of question/answer > >I am pretty new to XML, but basically I made something like this: ><products> > <product> > <name>prod1</name> > <partNum>prod1</partNum> > <categories> > <category> > <name>basic category</name> > <faqs> > <faq> > <question>This is a sample question</question> > <answer>this is the answer</answer> > </faq> > </faqs> > </category> > </categories> > </product> > <product> > <name>prod2</name> > <partNum>prod2</partNum> > <categories> > <category> > <name>basic something or something category</name> > <faqs> > <faq> > <question>This is another question</question> > <answer>and this is another answer</answer> > </faq> > </faqs> > </category> > </categories> > </product> ></products> > > > >So, then I use a DataSet and the ReadXML() method, this result in 5tables. >I was hoping that it would somehow be nested for me, but the way it isright >now I can't see an easy way to use it the way I want. > >the first table lists the products(good) >the second table I can't really tell what is in there >third tables has all the categories, so on and so on. > >What is confusing is... what is the point of structuring datahierarchically >in XML file if you can't maintain it? I'm sure you can, but how? Iswhat >I'm doing not common? > >Someone please shed a little light on this for me, I would appreciateit!! > >Thanks, >Steve >
great, thanks Mary!
"Mary Chipman" <mc***@nomail.please> wrote in message
news:4v********************************@4ax.com... Once you add the data to a dataset you can then set the DataRelations between the different DataTables. There's examples in online help -- see the topic "Adding a Relationship between Tables". Gotdotnet.com probably has other examples or tutorials as well. Then once you've set up the relations, you can then set the nested property to true.
-- Mary MCW Technologies http://www.mcwtech.com
On Mon, 8 Dec 2003 09:53:32 -0800, "neverstill" <sk************@yahoo.com> wrote:
Hi Mary, thanks for the response.
So I would setup the relationions prior to reading teh XML, correct?
Haveyou ever seen any examples of this?
Thanks again, Steve
"Mary Chipman" <mc***@nomail.please> wrote in message news:qh********************************@4ax.com.. . Create a dataset with datarelations between the tables you want nested. Set the Nested property prior to writing the xml:
ds.Relations["relationName"].Nested = true;
-- Mary MCW Technologies http://www.mcwtech.com
On Thu, 4 Dec 2003 16:44:58 -0800, "Steve Klett" <sk************@yahoo.com> wrote:
>(I posted this in ADO group, but I think this group will be better) > >Hi- > >I need to develop an FAQ section for our website. We would like to
breakup >the FAQ by products, then categories with each category having n >question/answer pairs. >I would like to pass parameters in the querystring based on what the >product/category the user selected, then populate a datagrid with the >correct set of question/answer > >I am pretty new to XML, but basically I made something like this: ><products> > <product> > <name>prod1</name> > <partNum>prod1</partNum> > <categories> > <category> > <name>basic category</name> > <faqs> > <faq> > <question>This is a sample question</question> > <answer>this is the answer</answer> > </faq> > </faqs> > </category> > </categories> > </product> > <product> > <name>prod2</name> > <partNum>prod2</partNum> > <categories> > <category> > <name>basic something or something category</name> > <faqs> > <faq> > <question>This is another question</question> > <answer>and this is another answer</answer> > </faq> > </faqs> > </category> > </categories> > </product> ></products> > > > >So, then I use a DataSet and the ReadXML() method, this result in 5 tables. >I was hoping that it would somehow be nested for me, but the way it is right >now I can't see an easy way to use it the way I want. > >the first table lists the products(good) >the second table I can't really tell what is in there >third tables has all the categories, so on and so on. > >What is confusing is... what is the point of structuring data hierarchically >in XML file if you can't maintain it? I'm sure you can, but how? Is what >I'm doing not common? > >Someone please shed a little light on this for me, I would appreciate it!! > >Thanks, >Steve > This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Eric Bohlman |
last post by:
What's the correct technique for nesting a bordered table inside of cell of
another bordered table without getting a double-thickness border around the
nested table? This is assuming the...
|
by: da_fox |
last post by:
Ok. I give up. I appeal to the css gurus out there for their
benevolence.
I'm trying to center some text on an arbitrary vertical on a page
using CSS instead of nested tables. It seems so easy...
|
by: T. Bjarne |
last post by:
I'm writing a form with a grid layout (similar to the ones in
phpMyAdmin). The form will contain X number of columns and Y rows - all
cells containg INPUT elements.
As long as the data isn't...
|
by: Hazz |
last post by:
I have 5 tables in SQL Server. Each with the following design and a sample
chain of the relationships from the root (WRL - World)
UUS is the 'Code' of the first table and it is the 'Parent' value...
|
by: George Durzi |
last post by:
I have a DataSet with 3 tables, and two DataRelations
dsSubs.Tables.TableName = "Subscriptions"
dsSubs.Tables.TableName = "AccountManagers"
dsSubs.Relations.Add
"AccountManagers_Subscriptions",...
|
by: Eirik Eldorsen |
last post by:
Im trying to make a nested repeater with 3 levels. I've successfully created
a nested repeater with 2 levels, but when adding the 3rd level I get an
InvalidCastException. What am I doing wrong?
...
|
by: fishwick |
last post by:
I haven't really done any css in quite a while, and am banging my head
against the wall trying get the rudimentary layout together of a church
website home page to display correctly - I don't want...
|
by: Shannon Jacobs |
last post by:
The OL tag still allows for a START value, but that is now deprecated.
I've found sound references that suggest the proper technique now is
to control it with a style for the OL in quetion, but I...
|
by: Me LK |
last post by:
I have a set of drop downs nested in a datagrid. Each drop down is a
size or color for an item. Each row of the grid has a button which
leads to a cart. When a user selects something from the...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
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...
|
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...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
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...
|
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...
|
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,...
| |