Oracle SQL Functions Flashcards
6 cards from real Oracle SQL practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 6 Oracle SQL Functions flashcards as text
Which Oracle SQL function converts a string to uppercase?
Answer: UPPER
The UPPER function converts all characters in a string to uppercase letters.
What does the NVL function do in Oracle SQL?
Answer: Replaces a NULL value with a specified substitute value
NVL(expr, replacement) returns the replacement value when expr is NULL, otherwise returns expr unchanged.
Which Oracle SQL function returns the number of characters in a string?
Answer: LENGTH
The LENGTH function returns the number of characters in a string, or NULL if the string is NULL.
What does the ROUND function do in Oracle SQL when called as ROUND(45.678, 1)?
Answer: Returns 45.7
ROUND(45.678, 1) rounds to one decimal place, returning 45.7.
Which Oracle SQL function extracts a portion of a string starting at a given position?
Answer: SUBSTR
SUBSTR(string, start, length) extracts a substring starting at the given position for a specified number of characters.
What does the TRUNC(45.789) function return in Oracle SQL?
Answer: 45
TRUNC without a second argument removes all decimal places, returning the integer portion 45 without rounding.