Oracle SQL SELECT Statements 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 SELECT Statements flashcards as text
What does the DUAL table represent in Oracle SQL?
Answer: A special one-row, one-column table used for evaluating expressions
DUAL is a special Oracle table with one row and one column, used to evaluate expressions or call functions without referencing a real table.
Which Oracle SQL clause is used to eliminate groups that don't meet a condition after GROUP BY?
Answer: HAVING
HAVING filters grouped rows based on aggregate conditions, while WHERE filters individual rows before grouping.
What is the result of dividing a number by zero in Oracle SQL?
Answer: Raises an ORA-01476 error
Oracle raises ORA-01476 'divisor is equal to zero' error when a division by zero occurs in a query.
In a SELECT statement, which order do clauses execute logically in Oracle SQL?
Answer: FROM → WHERE → GROUP BY → HAVING → SELECT → ORDER BY
Oracle processes clauses in this logical order: FROM, WHERE, GROUP BY, HAVING, SELECT, ORDER BY, even though SELECT is written first.
Which Oracle SQL function returns the current date and time including seconds?
Answer: SYSDATE
SYSDATE returns the current date and time from the database server, including hours, minutes, and seconds.
What does the BETWEEN operator do in Oracle SQL?
Answer: Checks if a value falls within an inclusive range
BETWEEN tests whether a value is within a range inclusively, equivalent to value >= lower AND value <= upper.