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 month value out of date passed
string-length(str)
month-from-date(date)
books/book[1]
year-from-date(current-date())
2. Seven kinds of nodes in XPath: element - attribute - text - namespace - __________ - comment - document (root) nodes - a.k.a. DECANT-PI
processing-instruction
path expressions
string-length(str)
transforming
3. Returns false if true - true if false (negative logic)
not(arg)
substring-after(str1, str2)
/bookstore/*
trees of nodes
4. XSL is what we use to get from readable to _________
usable document
Xpath operators
floor(num)
ceiling(num)
5. Selects all title elements of the book element AND all price elements in the entire document
nodes
string-length(str)
/bookstore/book/title | //price
floor(num)
6. XPath contains a library of _________
transformation
normalize-space(str)
standard function
upper-case(str)
7. ________ allow more specific selections within the XPath
upper-case(str)
timezone-from-time(time)
month-from-date(date)
Predicates
8. selects first book element from the children of books element
string-join((str1, str2, str3), separator)
index-of((item1, item2), item3...), target)
books/book[1]
transforming
9. Selects from the root node
'/'
10. Selects last book element from the children of books element
//book/title | //book/price
processing-instruction
current-dateTime()
books/book[last()]
11. Concatenates strings together with separator between each string
string-join((str1, str2, str3), separator)
path expressions
seconds-from-time(time)
minutes-from-time(time)
12. Returns n-length substring from start position
trees of nodes
child nodes
starts-with(str1, str2)
substring(str1, start, len)
13. Removes item in the position - example: remove(("ab", "cd", "ef"), 1) returns ("cd", "ef")
//title[@*]
substring-before(str1, str2)
remove((item1, item2, item3...), position)
nodes
14. xpath function categories: numeric - string - boolea - date/time - ________
current-time()
sequence
day-from-date(date)
floor(num)
15. Selects all title AND price elements of all book elements
//book/title | //book/price
upper-case(str)
not(arg)
arrays and functions
16. Inserts new itemX into the collection at the positionX - example insert-before("a", "b", "c"), 3, "z") returns (abzc)
floor(num)
not(arg)
/bookstore/*
insert-before((item1, item2, item3...), positionX, itemX)
17. In str1, replaces all occurrences of str2 with str3
..
replace(str1, str2, str3)
'/'
floor(num)
18. Returns next lowest integer
current-time()
round(num)
attribute node
floor(num)
19. Returns false or true
books/book[position()
substring(str,start)
boolean(arg)
month-from-date(date)
20. Returns boolean true or boolean false
timezone-from-time(time)
true() and false()
contains(str1, str2)
'//'
21. 3 parts of XSL (eXtensible stylesheet language): Xpath for navigating XML documents - XSLT for ______ documents - XSL-FO for formatting XML documents
number(arg)
arrays and functions
transforming
round(num)
22. Returns year value out of the date passed
ceiling(num)
year-from-date(date)
/bookstore/*
nodes
23. Returns everything after the first occurrence of str2
lower-case(str)
substring-after(str1, str2)
number(arg)
.
24. 3 wildcards: ? matches any element node - @ matches any ___________ - node() matches any node of any kind
attribute node
minutes-from-time(time)
/bookstore/book/title | //price
lower-case(str)
25. Element nodes may have zero - one - or more _________
substring-after(str1, str2)
child nodes
abs(num)
current-time()
26. The process of taking raw XML - adding XSL - and outputting a document file of some type
transformation
index-of((item1, item2), item3...), target)
month-from-date(date)
month-from-date(current-date())
27. Returns October or 10 ?
remove((item1, item2, item3...), position)
books/book[price > 35.00]
month-from-date(current-date())
books/book[last()]
28. Replaces chars of str2 found in str1 with chars of str3
upper-case(str)
translate(str1, str2, str3)
matches(str1, str2)
books/book[price > 35.00]
29. Converts string to upper case
not(arg)
translate(str1, str2, str3)
upper-case(str)
string-length()
30. +, -, *, div, =, !=, <, <=, >, >=, or, and, mod (modulus)
Xpath operators
/bookstore/book/title | //price
true() and false()
..
31. Returns today's date
string-join((str1, str2, str3), separator)
substring-after(str1, str2)
'/'
current-date()
32. Selects first two book elements from the children of books element
.
minutes-from-time(time)
books/book[position()
translate(str1, str2, str3)
33. Returns length of passed string
hours-from-time(time)
month-from-date(current-date())
ends-with(str1, str2)
string-length(str)
34. Returns substring from start position to end of string
insert-before((item1, item2, item3...), positionX, itemX)
parent node
substring(str1, start, len)
substring(str,start)
35. 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
36. Selects all book elements with an attribute isbn=
day-from-date(date)
//book[@isbn]
not(arg)
replace(str1, str2, str3)
37. Sibling nodes all have the same ______
trees of nodes
parent
.
instinct-values(item1, item2, item3...))
38. _______ have 3 primary relationships: parent - child - sibling
contains(str1, str2)
nodes
processing-instruction
boolean(arg)
39. Returns timezone value from time passed
timezone-from-time(time)
books/book[position()
.
matches(str1, str2)
40. XPath is a for defining parts of an XML document
criteria
path expressions
syntax
replace(str1, str2, str3)
41. Converts string to lower case
lower-case(str)
substring(str,start)
translate(str1, str2, str3)
//title | //price
42. XML documents are treated as _________- so the root of the tree is called the document node or root node
attribute node
..
trees of nodes
floor(num)
43. Transformation is actually accomplished by a _____________ like Saxon XSLT
processor application
books/book[1]
trees of nodes
minutes-from-time(time)
44. 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
string-length()
string-join((str1, str2, str3), separator)
ceiling(num)
criteria
45. Returns true if str1 starts with str2
starts-with(str1, str2)
Predicates
books/book[price > 35.00]
//title | //price
46. Selects parent of current node
..
child nodes
instinct-values(item1, item2, item3...))
year-from-date(date)
47. Selects all title AND price elements in the entire document
attribute node
//title | //price
timezone-from-time(time)
syntax
48. Selects current node
nodes
parent node
string-join((str1, str2, str3), separator)
.
49. Returns everything before the first occurrence of str2
normalize-space(str)
arrays and functions
substring-before(str1, str2)
books/book[position()
50. Compares strings, returns 0 if same, -1 if not same
compare(arg1, arg2)
arrays and functions
syntax
string-length()