Oracle
1Z0-061 · Question #247
Examine this statement: SELECT student_id, gpa FROM student_grades WHERE gpa > &&value; You run the statement once, and when prompted you enter a value of 2.0. A report is produced. What happens…
The correct answer is C. A report is produced that matches the first report produced. Use the double-ampersand if you want to reuse the variable value without prompting the user
Retrieving Data using the SQL SELECT Statement
Question
Examine this statement:
SELECT student_id, gpa FROM student_grades WHERE gpa > &&value; You run the statement once, and when prompted you enter a value of 2.0. A report is produced. What happens when you run the statement a second time?
Options
- AAn error is returned.
- BYou are prompted to enter a new value.
- CA report is produced that matches the first report produced.
- DYou are asked whether you want a new value or if you want to run the report based on the
How the community answered
(19 responses)- A16% (3)
- B5% (1)
- C74% (14)
- D5% (1)
Explanation
Use the double-ampersand if you want to reuse the variable value without prompting the user
Topics
#double ampersand substitution#bind variables#SQL*Plus#variable reuse
Community Discussion
No community discussion yet for this question.