What's the xpath to retrieve the value of
/root/main/data/data1
of the 1st section, where sibling
/root/main/info[@name='info1'] has value 'value_1a'?
In article <[email protected]>,
<[email protected]> wrote:
What's the xpath to retrieve the value of
/root/main/data/data1
of the 1st section, where sibling
/root/main/info[@name='info1'] has value 'value_1a'?
You want the data/data1 of the root/main whose info[@name="info_1"]
is equal to "value_1a":
/root/main[info[@name="info_1"]="value_1a"]/data/data1
-- Richard
Two next questions:
1) Is it really "info_1" to use? or does it have to be 'info_1'?
(double quote or single quote)
2) Is it also supported to use a combination of criterions?
Something like e.g.:
/root/main[info[@name="info_1"]="value_1a"]&&[@name="info_2"]="value_2a"]/data/data1
Are logical operators supported? (&& above)
In article <[email protected]>,
<[email protected]> wrote:
Two next questions:
1) Is it really "info_1" to use? or does it have to be 'info_1'?
(double quote or single quote)
You can use either kind of quote.
2) Is it also supported to use a combination of criterions?
Something like e.g.:
/root/main[info[@name="info_1"]="value_1a"]&&[@name="info_2"]="value_2a"]/data/data1
Are logical operators supported? (&& above)
That would be
/root/main[info[@name="info_1"]="value_1a" and info[@name="info_2"]="value_2a"]/data/data1
-- Richard
In article <[email protected]>,
<[email protected]> wrote:
Two next questions:
1) Is it really "info_1" to use? or does it have to be 'info_1'?
(double quote or single quote)
You can use either kind of quote.
| Sysop: | Keyop |
|---|---|
| Location: | Huddersfield, West Yorkshire, UK |
| Users: | 715 |
| Nodes: | 16 (2 / 14) |
| Uptime: | 146:45:46 |
| Calls: | 12,091 |
| Calls today: | 4 |
| Files: | 15,000 |
| Messages: | 6,517,509 |