View Single Post
  #2 (permalink)  
Old October 10th, 2006, 02:22 AM
joefawcett's Avatar
joefawcett joefawcett is offline
Wrox Author
Points: 9,763, Level: 42
Points: 9,763, Level: 42 Points: 9,763, Level: 42 Points: 9,763, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Exeter, , United Kingdom.
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

Assuming you're using version 1.0 then I think you need to combine the starts-with() and substring-after() string functions. So a possible XPath would be:
Code:
/ns:catalog/ns:dir[starts-with(ns:id, 'user:') and substring-after(ns:id, '/') = 'home']
You will have to declare the ns prefix as bound to the default namespace. For links on this subject see http://p2p.wrox.com/topic.asp?TOPIC_ID=49630.

--

Joe (Microsoft MVP - XML)
Reply With Quote