jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ed <...@SummitBid.com>
Subject XPath Ext. and looping over xml elements
Date Wed, 08 Oct 2008 20:22:59 GMT
I'm trying to iterate over the elements of an xml file and get the assetID
of each element. I'm able to get the assetID of the first element
"FolderProperties", but none of the rest.

How do I get some loop controller to continue down the xml elements and
process each "ChildFolder" element?

The XML looks like this:

<RootContents totalResults="18">
    <FolderProperties assetID="0cc80002" barkerSourceID="23071"
displayName="Tier3" parentAssetID="0cc80001" parentProviderID="*"
providerID="*"/>
    <ChildFolder assetID="0cc8011f" barkerSourceID="23071" displayName="Top
Picks" parentAssetID="0cc80002" parentProviderID="*" providerID="*"/>
    <ChildFolder assetID="0cc80101" barkerSourceID="23071"
displayName="Movies &amp; Events" parentAssetID="0cc80002"
parentProviderID="*" providerID="*"/>
 ...
    <ChildFolder assetID="0cc80a7e" barkerSourceID="23071"
displayName="RNG-Level1" parentAssetID="0cc80002" parentProviderID="*"
providerID="*"/>
    <ChildFolder assetID="0cc80bfa" barkerSourceID="23071" displayName="All
Movies" parentAssetID="0cc80002" parentProviderID="*" providerID="*"/>
</RootContents>

I'm able to get the first asetID with
/RootContents/FolderProperties/@assetID

But when I try to get the rest in a Loop Controller with
/RootContents/ChildFolder/@assetID

I get only the first one "<FolderProperties assetID="0cc800002"...

Thanks,



-- 
Ed

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message