Shruthi_R 0 Newbie Poster

this is one feed

- <category name="Television" timeGenerated="2007-05-28T23:21:13" >
- <event name="Channel1" eventid="573512.20" date="20090701" time="1000" meeting="" >
- <televisiontype  name=" Outright" inrunning="0">
  <TV name="Videocon" id="16007131.20" price="$222"  /> 
  <TV name="Philips" id="16007132.20" price="$322" /> 
  <TV  name="Western" id="16007133.20" price="$121"  /> 
  </televisiontype>
  </event>

  </category>

this is another XML feed

<?xml version="1.0" encoding="UTF-8" ?><!DOCTYPE abcd SYSTEM "abcd.dtd"><abcd version="6.0" created="2007-05-29 06:15:26" lastMsgId="3080173">
  <response>
    <returnStatus>
      <code>100</code>
      <message>success</message>
    </returnStatus>
    <respQueryApplyXSLT>


        <class>
          <id>9</id>
          <name>Television</name>

          <type>
            <id>4020</id>
            <name>Videocon</name>

            <event>
              <id>2890</id>
              <name>channel1</name>
              <date>2007-06-07</date>
              <time>09:30:00</time>

              <market>
                <id>11819</id>
                <name>Asia</name>
                <eachway>
                  <reduction>/</reduction>
                  <place/>
                </eachway>
                <outcome>
                  <name>Speaker</name>
                  <price>$2000</price>
                </outcome>
</type>
<type>
            <id>4020</id>
            <name>Philips</name>

            <event>
              <id>2890</id>
              <name>channel1</name>
              <date>2007-06-07</date>
              <time>09:30:00</time>

              <market>
                <id>11819</id>
                <name>Africa</name>
                <eachway>
                  <reduction>/</reduction>
                  <place/>
                </eachway>
                <outcome>
                  <name>Speaker</name>
                  <price>$2100</price>
                </outcome>
</type>
</class>
</respQueryApplyXSLT>
</response>
</abcd>

now i have database fields like

categoryname
eventname
Typename
Price

from the first set of xml feeds i have done like

xmldocument xmldoc=new xmldocument();
xmldoc.LoadXML(URL);
Xmlnode nevents=xmldoc.Childnodes[0];
categoryname=nevents.attributes["name"];
foreach(xmlnode nevent in nevents)
{
eventname=?
foreach(xmlnode type in nevent.childnodes)
{
typename=?
foreach(Xmlnode nprice in type)
{
price=?
}
}
}

now taking a look at the second xml feed the contents are same like
i need to match the price alone
for example i need to load only the price for videocon from the second feed matching the first feed
i dont know how to proceed on this
plz help me on this regard
Shruthi

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.