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. Compares strings, returns 0 if same, -1 if not same
compare(arg1, arg2)
/bookstore/*
translate(str1, str2, str3)
matches(str1, str2)
2. 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...))
substring-after(str1, str2)
day-from-date(date)
//title | //price
3. Selects all title elements of the book element AND all price elements in the entire document
..
lower-case(str)
path expressions
/bookstore/book/title | //price
4. Returns October or 10 ?
substring(str,start)
month-from-date(current-date())
concat(str1, str2, str3...)
year-from-date(current-date())
5. Concatenates strings together (example concat('It",'is','cool') returns "Itiscool"
nodes
//book/title | //book/price
concat(str1, str2, str3...)
..
6. Returns absolute value (example abs(-2.5) returns 2.5
attribute node
//title | //price
//title[@*]
abs(num)
7. Returns second value from time passed
sequence
books/book[last()]
number(arg)
seconds-from-time(time)
8. Selects last book element from the children of books element
lower-case(str)
/bookstore/*
//title | //price
books/book[last()]
9. xpath function categories: numeric - string - boolea - date/time - ________
path
string(arg)
XSLT
sequence
10. Returns n-length substring from start position
month-from-date(current-date())
.
ends-with(str1, str2)
substring(str1, start, len)
11. Converts value to a string
contains(str1, str2)
'/'
string(arg)
books/book[1]
12. Selects all the child nodes of the bookstore element
ends-with(str1, str2)
string-length(str)
/bookstore/*
attribute node
13. Predicates work somewhat like _____________
trees of nodes
arrays and functions
number(arg)
XSLT
14. 3 wildcards: ? matches any element node - @ matches any ___________ - node() matches any node of any kind
standard function
attribute node
parent
current-date()
15. Returns false or true
//title[@*]
boolean(arg)
concat(str1, str2, str3...)
/bookstore/*
16. Returns true if str1 contains str2
/bookstore/*
contains(str1, str2)
upper-case(str)
path expressions
17. Sibling nodes all have the same ______
/bookstore/*
substring(str,start)
parent
transformation
18. Returns false if true - true if false (negative logic)
criteria
index-of((item1, item2), item3...), target)
month-from-date(current-date())
not(arg)
19. Selects from the root node
'/'
20. Converts string to lower case
books/book[price > 35.00]
hours-from-time(time)
usable document
lower-case(str)
21. Returns true if str2 appears anywhere inside str1
matches(str1, str2)
lower-case(str)
'//'
current-date()
22. The process of taking raw XML - adding XSL - and outputting a document file of some type
transformation
current-time()
processor application
index-of((item1, item2), item3...), target)
23. Returns next lowest integer
attribute node
path
.
floor(num)
24. Concatenates strings together with separator between each string
string-join((str1, str2, str3), separator)
//title | //price
timezone-from-time(time)
child nodes
25. every element and every attribute have just one _________
parent node
floor(num)
replace(str1, str2, str3)
abs(num)
26. ________ allow more specific selections within the XPath
Predicates
year-from-date(current-date())
string-join((str1, str2, str3), separator)
books/book[last()]
27. Converts string number to numeric value
Predicates
number(arg)
day-from-date(date)
child nodes
28. Selects all title AND price elements of all book elements
//book/title | //book/price
boolean(arg)
day-from-date(date)
current-time()
29. Returns everything before the first occurrence of str2
substring-before(str1, str2)
current-dateTime()
string-join((str1, str2, str3), separator)
day-from-date(date)
30. Returns minute value from time passed
substring-after(str1, str2)
minutes-from-time(time)
books/book[position()
standard function
31. Selects all book elements with an attribute isbn=
//book[@isbn]
substring(str,start)
trees of nodes
books/book[1]
32. Selects first two book elements from the children of books element
string-length(str)
'//'
year-from-date(current-date())
books/book[position()
33. XPath uses ____________ to navigate in XML documents - selecting nodes or node-sets
remove((item1, item2, item3...), position)
path expressions
books/book[last()]
ceiling(num)
34. XPath is a for defining parts of an XML document
true() and false()
syntax
path
matches(str1, str2)
35. Returns length of passed string
remove((item1, item2, item3...), position)
year-from-date(current-date())
substring-before(str1, str2)
string-length(str)
36. selects first book element from the children of books element
/bookstore/book/title | //price
books/book[1]
year-from-date(date)
abs(num)
37. Selects all elements in the document
replace(str1, str2, str3)
XSLT
attribute node
//*
38. Travels from current node to select nodes that match - wherever they are
39. Returns 2008
criteria
year-from-date(current-date())
transformation
nodes
40. XSL is what we use to get from readable to _________
translate(str1, str2, str3)
abs(num)
compare(arg1, arg2)
usable document
41. The XPath division operator not "/" cuz "/" is used in path expressions
div
insert-before((item1, item2, item3...), positionX, itemX)
substring(str1, start, len)
processing-instruction
42. Returns boolean true or boolean false
true() and false()
attribute node
boolean(arg)
lower-case(str)
43. Selects parent of current node
ends-with(str1, str2)
..
criteria
path expressions
44. Returns next highest integer
path
//title[@*]
substring(str,start)
ceiling(num)
45. Returns complete date/time
current-dateTime()
child nodes
substring(str1, start, len)
sequence
46. Returns timezone value from time passed
starts-with(str1, str2)
not(arg)
timezone-from-time(time)
transformation
47. Returns true if str1 ends with str2
ends-with(str1, str2)
nodes
starts-with(str1, str2)
//*
48. Selects current node
path
books/book[1]
floor(num)
.
49. _______ have 3 primary relationships: parent - child - sibling
/bookstore/book/title | //price
concat(str1, str2, str3...)
nodes
timezone-from-time(time)
50. Returns length of current node string
books/book[position()
number(arg)
string-length()
concat(str1, str2, str3...)