| Join wMUsers | Blog at wMUsers | User Control Panel | Site Map | webMethods Jobs |For Employers |
![]() |
![]() |
IntroductionMapping data from deeply hierarchical data structures is a challenging and time-consuming task for webMethods developers. The underused and powerful Allowing the developer to use the XQL and WQL query languages on webMethods Records, Query language syntax is based on a basic URI syntax best illustrated by example. This webMethods Ezine article uses XQL in its examples, but beyond the syntax differences of the two languages, the two options offer similar functionality. Sample XML DocumentThe XML document is the basis for all XQL queries in the article: <Transaction>
<Header>
<Party role="Buyer">
<Code type="DUNS">123456789</Code>
<Name>CompanyX</Name>
<Contact>
<Name>Sam the Buyer</Name>
<Address>
<Street>555 Bill Ave</Street>
<City>Dallas</City>
<State>Texas</State>
<Country>USA</Country>
</Address>
<PhoneNumber>555-555-4444</PhoneNumber>
</Contact>
</Party>
<Party role="Seller">
<Code type="DUNS">456789123</Code>
<Name>CompanyY</Name>
<Contact>
<Name>Jill the Seller</Name>
<Address>
<Street>12343 Joe Street</Street>
<City>Seattle</City>
<State>Washington</State>
<Country>USA</Country>
</Address>
<PhoneNumber>555-555-5555</PhoneNumber>
</Contact>
</Party>
<SubmitDate>01-01-2003</SubmitDate>
</Header>
<Details>
<Item number="1">
<IDNumber>11111</IDNumber>
<Amount>100.11</Amount>
<Account>10001</Account>
<ServiceDate>01-12-2002</ServiceDate>
</Item>
<Item number="2">
<IDNumber>22222</IDNumber>
<Amount>200.22</Amount>
<Account>20002</Account>
<ServiceDate>02-12-2002</ServiceDate>
</Item>
<Item number="3">
<IDNumber>33333</IDNumber>
<Amount>300.33</Amount>
<Account>30003</Account>
<ServiceDate>03-12-2002</ServiceDate>
</Item>
<Item number="4">
<IDNumber>44444</IDNumber>
<Amount>400.44</Amount>
<Account>40004</Account>
<ServiceDate>04-12-2002</ServiceDate>
</Item>
</Details>
</Transaction>
Basic XQL syntaxAs mentioned earlier, the easiest way to explain query language is by example so let's look at the return values of some XQL queries on the XML document described above.
To narrow results, there are common operators that can be applied to the query statement. Conditions are expressed inside of brackets ("[" and "]") and the operators "=", "!=", "<", ">" can be used for comparisons.
The above examples, by no means, cover the full range of features supported by XQL. Please refer to the ISDeveloperGuide.pdf for a complete coverage XQL and WQL features. Flow development using
|
| © All Rights Reserved, 2001-2008. |