SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
XML XPATH
Start Test
Study First
Subject
:
it-skills
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. Sibling nodes all have the same ______
//book/title | //book/price
parent
books/book[price > 35.00]
'/'
2. XPath contains a library of _________
standard function
@
remove((item1, item2, item3...), position)
true() and false()
3. Returns absolute value (example abs(-2.5) returns 2.5
year-from-date(date)
nodes
abs(num)
substring-before(str1, str2)
4. Converts value to a string
trees of nodes
year-from-date(date)
string(arg)
books/book[price > 35.00]
5. Returns minute value from time passed
Predicates
minutes-from-time(time)
ceiling(num)
nodes
6. Selects all title AND price elements of all book elements
//*
syntax
//book/title | //book/price
month-from-date(date)
7. Selects last book element from the children of books element
contains(str1, str2)
books/book[last()]
//title[@*]
true() and false()
8. Returns October or 10 ?
month-from-date(current-date())
upper-case(str)
transformation
normalize-space(str)
9. Selects all title AND price elements in the entire document
//book[@isbn]
//title | //price
substring-after(str1, str2)
seconds-from-time(time)
10. Selects first two book elements from the children of books element
books/book[position()
upper-case(str)
attribute node
books/book[last()]
11. XPath is a major element in _______
XSLT
normalize-space(str)
index-of((item1, item2), item3...), target)
hours-from-time(time)
12. XML documents are treated as _________- so the root of the tree is called the document node or root node
ends-with(str1, str2)
..
trees of nodes
'/'
13. 3 parts of XSL (eXtensible stylesheet language): Xpath for navigating XML documents - XSLT for ______ documents - XSL-FO for formatting XML documents
/bookstore/*
transforming
seconds-from-time(time)
true() and false()
14. Returns substring from start position to end of string
boolean(arg)
substring(str,start)
month-from-date(current-date())
translate(str1, str2, str3)
15. Returns everything after the first occurrence of str2
substring-after(str1, str2)
current-dateTime()
path
..
16. Returns timezone value from time passed
string-length(str)
timezone-from-time(time)
contains(str1, str2)
transformation
17. Returns n-length substring from start position
instinct-values(item1, item2, item3...))
substring(str1, start, len)
//book/title | //book/price
day-from-date(date)
18. Selects all book elements with a child element "price" with values greater than 35
books/book[price > 35.00]
instinct-values(item1, item2, item3...))
boolean(arg)
substring(str,start)
19. Returns true if str2 appears anywhere inside str1
day-from-date(date)
string-length()
matches(str1, str2)
books/book[price > 35.00]
20. Returns month value out of date passed
criteria
month-from-date(date)
seconds-from-time(time)
current-date()
21. Concatenates strings together with separator between each string
//*
books/book[price > 35.00]
parent node
string-join((str1, str2, str3), separator)
22. The XPath division operator not "/" cuz "/" is used in path expressions
month-from-date(current-date())
true() and false()
standard function
div
23. A predicate is used by is used by adding square brackets [ ] to the end of a path or portion of a path - and adding ________ inside the brackets
remove((item1, item2, item3...), position)
/bookstore/book/title | //price
trees of nodes
criteria
24. Selects all the child nodes of the bookstore element
seconds-from-time(time)
/bookstore/*
starts-with(str1, str2)
translate(str1, str2, str3)
25. Returns false or true
boolean(arg)
hours-from-time(time)
parent
usable document
26. +, -, *, div, =, !=, <, <=, >, >=, or, and, mod (modulus)
Xpath operators
abs(num)
remove((item1, item2, item3...), position)
seconds-from-time(time)
27. Selects from the root node
'/'
28. Selects all book elements with an attribute isbn=
'//'
//book[@isbn]
normalize-space(str)
Predicates
29. Selects all title elements of the book element AND all price elements in the entire document
/bookstore/book/title | //price
hours-from-time(time)
current-date()
arrays and functions
30. Concatenates strings together (example concat('It",'is','cool') returns "Itiscool"
current-time()
transforming
concat(str1, str2, str3...)
not(arg)
31. Returns 2008
year-from-date(current-date())
@
seconds-from-time(time)
substring(str1, start, len)
32. Returns true if str1 starts with str2
XSLT
starts-with(str1, str2)
'//'
//book/title | //book/price
33. The process of taking raw XML - adding XSL - and outputting a document file of some type
lower-case(str)
transformation
day-from-date(date)
path expressions
34. XSL is what we use to get from readable to _________
number(arg)
ceiling(num)
/bookstore/book/title | //price
usable document
35. Returns length of current node string
attribute node
standard function
Xpath operators
string-length()
36. Returns true if str1 ends with str2
string(arg)
ends-with(str1, str2)
//book/title | //book/price
contains(str1, str2)
37. Selects current node
/bookstore/*
current-dateTime()
//title[@*]
.
38. Use a | to select more than one _____ (means AND)
standard function
path
substring(str1, start, len)
normalize-space(str)
39. _______ have 3 primary relationships: parent - child - sibling
arrays and functions
substring(str1, start, len)
nodes
.
40. Returns all unique values in that collection - example: distinct-values(a, b, c, d, a, c) returns (a, b, c, d)
instinct-values(item1, item2, item3...))
lower-case(str)
books/book[price > 35.00]
year-from-date(current-date())
41. Trims leading and trailing spaces
normalize-space(str)
concat(str1, str2, str3...)
current-date()
'/'
42. XPath is a for defining parts of an XML document
syntax
@
minutes-from-time(time)
current-time()
43. Returns boolean true or boolean false
true() and false()
index-of((item1, item2), item3...), target)
month-from-date(current-date())
path
44. Returns second value from time passed
seconds-from-time(time)
syntax
//book[@isbn]
boolean(arg)
45. Returns true if str1 contains str2
parent node
abs(num)
contains(str1, str2)
nodes
46. Returns false if true - true if false (negative logic)
parent node
nodes
not(arg)
child nodes
47. Travels from current node to select nodes that match - wherever they are
48. Seven kinds of nodes in XPath: element - attribute - text - namespace - __________ - comment - document (root) nodes - a.k.a. DECANT-PI
//title | //price
substring-before(str1, str2)
processing-instruction
substring(str,start)
49. Returns length of passed string
matches(str1, str2)
string-length(str)
current-date()
@
50. xpath function categories: numeric - string - boolea - date/time - ________
sequence
//book[@isbn]
string-join((str1, str2, str3), separator)
path