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. every element and every attribute have just one _________
index-of((item1, item2), item3...), target)
string-length(str)
parent node
replace(str1, str2, str3)
2. Selects all title AND price elements of all book elements
transformation
string-length(str)
//book/title | //book/price
criteria
3. Removes item in the position - example: remove(("ab", "cd", "ef"), 1) returns ("cd", "ef")
substring(str1, start, len)
remove((item1, item2, item3...), position)
current-dateTime()
year-from-date(current-date())
4. XSL is what we use to get from readable to _________
trees of nodes
Xpath operators
substring-before(str1, str2)
usable document
5. Seven kinds of nodes in XPath: element - attribute - text - namespace - __________ - comment - document (root) nodes - a.k.a. DECANT-PI
index-of((item1, item2), item3...), target)
not(arg)
..
processing-instruction
6. Returns all unique values in that collection - example: distinct-values(a, b, c, d, a, c) returns (a, b, c, d)
//*
seconds-from-time(time)
/bookstore/book/title | //price
instinct-values(item1, item2, item3...))
7. Returns minute value from time passed
boolean(arg)
usable document
month-from-date(date)
minutes-from-time(time)
8. Converts value to a string
string(arg)
standard function
'//'
minutes-from-time(time)
9. Returns October or 10 ?
month-from-date(current-date())
//title[@*]
/bookstore/book/title | //price
.
10. Returns everything before the first occurrence of str2
sequence
round(num)
substring-before(str1, str2)
hours-from-time(time)
11. Selects current node
attribute node
.
parent
books/book[price > 35.00]
12. Selects last book element from the children of books element
instinct-values(item1, item2, item3...))
books/book[last()]
remove((item1, item2, item3...), position)
//*
13. Returns true if str1 ends with str2
contains(str1, str2)
minutes-from-time(time)
ends-with(str1, str2)
insert-before((item1, item2, item3...), positionX, itemX)
14. Selects all the child nodes of the bookstore element
trees of nodes
string-join((str1, str2, str3), separator)
/bookstore/*
current-date()
15. Sibling nodes all have the same ______
parent
replace(str1, str2, str3)
starts-with(str1, str2)
normalize-space(str)
16. Transformation is actually accomplished by a _____________ like Saxon XSLT
day-from-date(date)
hours-from-time(time)
month-from-date(current-date())
processor application
17. XPath is a major element in _______
XSLT
current-date()
/bookstore/book/title | //price
'//'
18. Selects all title elements which have any attribute
//title[@*]
contains(str1, str2)
current-dateTime()
starts-with(str1, str2)
19. Replaces chars of str2 found in str1 with chars of str3
path
translate(str1, str2, str3)
string-join((str1, str2, str3), separator)
div
20. Use a | to select more than one _____ (means AND)
..
starts-with(str1, str2)
syntax
path
21. Element nodes may have zero - one - or more _________
child nodes
current-time()
transformation
starts-with(str1, str2)
22. Concatenates strings together (example concat('It",'is','cool') returns "Itiscool"
transformation
concat(str1, str2, str3...)
parent
month-from-date(date)
23. Returns true if str1 contains str2
Xpath operators
contains(str1, str2)
matches(str1, str2)
normalize-space(str)
24. Selects from the root node
'/'
25. Returns everything after the first occurrence of str2
.
year-from-date(current-date())
substring(str,start)
substring-after(str1, str2)
26. Inserts new itemX into the collection at the positionX - example insert-before("a", "b", "c"), 3, "z") returns (abzc)
/bookstore/book/title | //price
substring-before(str1, str2)
standard function
insert-before((item1, item2, item3...), positionX, itemX)
27. XPath contains a library of _________
month-from-date(date)
remove((item1, item2, item3...), position)
upper-case(str)
standard function
28. Concatenates strings together with separator between each string
@
current-date()
string-join((str1, str2, str3), separator)
'/'
29. Selects all elements in the document
//*
//title[@*]
abs(num)
attribute node
30. Returns hour value from time passed
hours-from-time(time)
number(arg)
string(arg)
books/book[last()]
31. 3 wildcards: ? matches any element node - @ matches any ___________ - node() matches any node of any kind
attribute node
@
//book/title | //book/price
//title[@*]
32. Returns logically rounded integer
seconds-from-time(time)
round(num)
Xpath operators
parent
33. Selects parent of current node
..
'//'
normalize-space(str)
upper-case(str)
34. Returns second value from time passed
seconds-from-time(time)
'/'
@
child nodes
35. Predicates work somewhat like _____________
month-from-date(date)
day-from-date(date)
substring-after(str1, str2)
arrays and functions
36. Selects first two book elements from the children of books element
books/book[position()
substring(str,start)
substring-after(str1, str2)
//title | //price
37. Returns complete date/time
upper-case(str)
current-dateTime()
sequence
translate(str1, str2, str3)
38. Returns length of passed string
usable document
month-from-date(current-date())
floor(num)
string-length(str)
39. Converts string to lower case
lower-case(str)
processor application
transformation
round(num)
40. Trims leading and trailing spaces
contains(str1, str2)
normalize-space(str)
sequence
timezone-from-time(time)
41. Returns false if true - true if false (negative logic)
not(arg)
books/book[position()
syntax
compare(arg1, arg2)
42. Selects all book elements with a child element "price" with values greater than 35
books/book[price > 35.00]
parent node
ceiling(num)
instinct-values(item1, item2, item3...))
43. XPath is a for defining parts of an XML document
transformation
syntax
@
current-date()
44. +, -, *, div, =, !=, <, <=, >, >=, or, and, mod (modulus)
@
Xpath operators
not(arg)
Predicates
45. xpath function categories: numeric - string - boolea - date/time - ________
sequence
//book/title | //book/price
year-from-date(date)
boolean(arg)
46. ________ allow more specific selections within the XPath
compare(arg1, arg2)
day-from-date(date)
starts-with(str1, str2)
Predicates
47. Returns day value from date passed
substring(str1, start, len)
day-from-date(date)
seconds-from-time(time)
substring-before(str1, str2)
48. Selects all title AND price elements in the entire document
current-time()
compare(arg1, arg2)
transformation
//title | //price
49. Returns true if str1 starts with str2
//*
round(num)
starts-with(str1, str2)
parent
50. Returns false or true
translate(str1, str2, str3)
..
boolean(arg)
usable document