View DataSet Relational Data

Discussion in 'ASP .Net Web Controls' started by Evan M., Jun 21, 2005.

  1. Evan M.

    Evan M. Guest

    Hello everybody, hopefully someone can help me with this, or point me
    in the right direction.

    I have a DataSet that I've read in from an XML file with an associated
    schema. The DataSet ends up with two tables: document and category.
    document contains document information, including a category ID inside
    of a <category> tag. The category table / XML entries only have two
    columns: <id> and <name>.

    Inside of my XSD file I've created the relationship between
    document:category and category:id (or atleast, so I believe). Now, I'm
    trying to get it so that in my repeater control that outputs the list
    of documents, rather than it showing the id number from
    document:category, it instead shows the related category:name
    associated with it. (i.e. it says "New Products" rather than the ID# of
    5).

    Anyone know how I can do this? Thanks
    Evan M.
     
    Evan M., Jun 21, 2005
    #1
    1. Advertising

  2. Evan M.

    Harolds Guest

    I haven't used it myself, but it seems that the DataViewManager is what you
    are looking for.

    Take a look at:
    ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.1033/cpguide/html/cpconsettingdefaulttableviewsusingdataviewmanager.htm

    "Evan M." wrote:

    > Hello everybody, hopefully someone can help me with this, or point me
    > in the right direction.
    >
    > I have a DataSet that I've read in from an XML file with an associated
    > schema. The DataSet ends up with two tables: document and category.
    > document contains document information, including a category ID inside
    > of a <category> tag. The category table / XML entries only have two
    > columns: <id> and <name>.
    >
    > Inside of my XSD file I've created the relationship between
    > document:category and category:id (or atleast, so I believe). Now, I'm
    > trying to get it so that in my repeater control that outputs the list
    > of documents, rather than it showing the id number from
    > document:category, it instead shows the related category:name
    > associated with it. (i.e. it says "New Products" rather than the ID# of
    > 5).
    >
    > Anyone know how I can do this? Thanks
    > Evan M.
    >
    >
     
    Harolds, Jun 22, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Doug
    Replies:
    3
    Views:
    371
  2. rmorvay
    Replies:
    1
    Views:
    422
    rmorvay
    Jun 4, 2004
  3. Carse
    Replies:
    1
    Views:
    3,659
    Carse
    Jan 28, 2005
  4. Saber

    Gridview and Relational data

    Saber, Apr 16, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    490
    Saber
    Apr 17, 2006
  5. Parthiv Joshi
    Replies:
    1
    Views:
    692
    Samuel L Matzen
    Jul 6, 2004
Loading...

Share This Page