Bird
0
0

What is the main purpose of an INOUT parameter in a SQL stored procedure?

easy📝 Conceptual Q1 of 15
SQL - Stored Procedures and Functions
What is the main purpose of an INOUT parameter in a SQL stored procedure?
AIt declares a constant value that cannot be changed inside the procedure.
BIt only passes a value into the procedure without returning anything.
CIt only returns a value from the procedure without accepting input.
DIt allows passing a value into the procedure and returning a modified value back.
Step-by-Step Solution
Solution:
  1. Step 1: Understand INOUT parameter behavior

    An INOUT parameter lets you send a value into the procedure and get a changed value back after execution.
  2. Step 2: Compare with other parameter types

    IN only sends values in, OUT only sends values out, but INOUT does both.
  3. Final Answer:

    It allows passing a value into the procedure and returning a modified value back. -> Option D
  4. Quick Check:

    INOUT = Input and output parameter [OK]
Quick Trick: INOUT means input and output combined [OK]
Common Mistakes:
  • Confusing INOUT with only IN or only OUT
  • Thinking INOUT cannot return values
  • Assuming INOUT is read-only

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More SQL Quizzes