I have an XML which looks something like this:
<Library>
<Author Name = "JRR Tolkien">
<Book Title = "Lord Of the Rings" />
<Book Title = "The Hobbit" />
</Author>
<Author Name = "JK Rowling">
<Book Title = "Harry Potter and the Sorcerers Stone" />
<Book Title = "Harry Potter and the Prisoner of Azkaban" />
</Author>
</Library>
What is the XPath to select all the “Book” nodes whose parent “Author” node has the value “JK Rowling”?
This is properly more most intuitive and strict which selects all the books which have a
AuthorwhichNameattribute is'JK Rowling'as a parent. And theAuthormust also have theLibraryas a parent.