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. Returns absolute value (example abs(-2.5) returns 2.5
string-join((str1, str2, str3), separator)
abs(num)
normalize-space(str)
replace(str1, str2, str3)
2. Converts string number to numeric value
number(arg)
upper-case(str)
timezone-from-time(time)
string-join((str1, str2, str3), separator)
3. Element nodes may have zero - one - or more _________
usable document
child nodes
translate(str1, str2, str3)
books/book[last()]
4. 3 wildcards: ? matches any element node - @ matches any ___________ - node() matches any node of any kind
ends-with(str1, str2)
index-of((item1, item2), item3...), target)
attribute node
books/book[price > 35.00]
5. Removes item in the position - example: remove(("ab", "cd", "ef"), 1) returns ("cd", "ef")
true() and false()
//book/title | //book/price
remove((item1, item2, item3...), position)
translate(str1, str2, str3)
6. Returns length of current node string
.
sequence
substring-before(str1, str2)
string-length()
7. Selects current node
substring(str,start)
.
/bookstore/book/title | //price
abs(num)
8. every element and every attribute have just one _________
Xpath operators
Predicates
parent node
processing-instruction
9. Selects all title AND price elements in the entire document
sequence
number(arg)
div
//title | //price
10. In str1, replaces all occurrences of str2 with str3
insert-before((item1, item2, item3...), positionX, itemX)
replace(str1, str2, str3)
trees of nodes
syntax
11. Returns everything before the first occurrence of str2
syntax
round(num)
substring-before(str1, str2)
insert-before((item1, item2, item3...), positionX, itemX)
12. Selects all the child nodes of the bookstore element
substring(str1, start, len)
'/'
string-length(str)
/bookstore/*
13. _______ have 3 primary relationships: parent - child - sibling
nodes
Xpath operators
trees of nodes
upper-case(str)
14. Use a | to select more than one _____ (means AND)
path
books/book[price > 35.00]
//book/title | //book/price
attribute node
15. Converts string to lower case
substring-before(str1, str2)
hours-from-time(time)
path
lower-case(str)
16. Transformation is actually accomplished by a _____________ like Saxon XSLT
processor application
timezone-from-time(time)
ends-with(str1, str2)
remove((item1, item2, item3...), position)
17. Returns month value out of date passed
current-date()
trees of nodes
month-from-date(date)
minutes-from-time(time)
18. Gets position(s) of target item(s) - example: index-of(15, 40, 25, 40, 10), 40) returns (2, 4)
criteria
not(arg)
timezone-from-time(time)
index-of((item1, item2), item3...), target)
19. Inserts new itemX into the collection at the positionX - example insert-before("a", "b", "c"), 3, "z") returns (abzc)
ceiling(num)
insert-before((item1, item2, item3...), positionX, itemX)
substring-after(str1, str2)
starts-with(str1, str2)
20. Selects first two book elements from the children of books element
month-from-date(date)
path
books/book[position()
substring-after(str1, str2)
21. Returns minute value from time passed
standard function
minutes-from-time(time)
replace(str1, str2, str3)
Xpath operators
22. Returns second value from time passed
upper-case(str)
seconds-from-time(time)
nodes
not(arg)
23. Returns n-length substring from start position
/bookstore/*
/bookstore/book/title | //price
substring(str1, start, len)
normalize-space(str)
24. Travels from current node to select nodes that match - wherever they are
Warning
: Invalid argument supplied for foreach() in
/var/www/html/basicversity.com/show_quiz.php
on line
183
25. Returns true if str2 appears anywhere inside str1
month-from-date(current-date())
year-from-date(date)
'/'
matches(str1, str2)
26. XML documents are treated as _________- so the root of the tree is called the document node or root node
/bookstore/book/title | //price
criteria
translate(str1, str2, str3)
trees of nodes
27. 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
criteria
.
books/book[1]
ceiling(num)
28. Returns day value from date passed
processing-instruction
Xpath operators
day-from-date(date)
.
29. 3 parts of XSL (eXtensible stylesheet language): Xpath for navigating XML documents - XSLT for ______ documents - XSL-FO for formatting XML documents
usable document
transforming
syntax
day-from-date(date)
30. Seven kinds of nodes in XPath: element - attribute - text - namespace - __________ - comment - document (root) nodes - a.k.a. DECANT-PI
string(arg)
books/book[price > 35.00]
processing-instruction
/bookstore/book/title | //price
31. Converts value to a string
attribute node
insert-before((item1, item2, item3...), positionX, itemX)
standard function
string(arg)
32. xpath function categories: numeric - string - boolea - date/time - ________
sequence
.
//*
minutes-from-time(time)
33. Returns false if true - true if false (negative logic)
processor application
not(arg)
number(arg)
parent node
34. Selects all elements in the document
div
syntax
//*
Predicates
35. The XPath division operator not "/" cuz "/" is used in path expressions
child nodes
Predicates
div
books/book[1]
36. Selects from the root node
'/'
37. Returns true if str1 contains str2
contains(str1, str2)
replace(str1, str2, str3)
floor(num)
arrays and functions
38. Returns timezone value from time passed
year-from-date(current-date())
'/'
timezone-from-time(time)
contains(str1, str2)
39. Selects all book elements with an attribute isbn=
nodes
insert-before((item1, item2, item3...), positionX, itemX)
//book[@isbn]
usable document
40. Returns today's date
XSLT
current-date()
current-dateTime()
concat(str1, str2, str3...)
41. Concatenates strings together (example concat('It",'is','cool') returns "Itiscool"
path expressions
concat(str1, str2, str3...)
current-date()
syntax
42. selects first book element from the children of books element
books/book[1]
upper-case(str)
//book[@isbn]
'/'
43. Selects all title AND price elements of all book elements
//book/title | //book/price
month-from-date(current-date())
compare(arg1, arg2)
//title[@*]
44. Selects attributes
day-from-date(date)
attribute node
@
criteria
45. XPath uses ____________ to navigate in XML documents - selecting nodes or node-sets
normalize-space(str)
path expressions
floor(num)
.
46. Returns substring from start position to end of string
insert-before((item1, item2, item3...), positionX, itemX)
instinct-values(item1, item2, item3...))
translate(str1, str2, str3)
substring(str,start)
47. Selects parent of current node
..
number(arg)
substring(str1, start, len)
ceiling(num)
48. Selects last book element from the children of books element
books/book[last()]
compare(arg1, arg2)
Predicates
usable document
49. Concatenates strings together with separator between each string
substring-before(str1, str2)
string-join((str1, str2, str3), separator)
//book[@isbn]
concat(str1, str2, str3...)
50. Returns year value out of the date passed
year-from-date(date)
timezone-from-time(time)
upper-case(str)
..