In SQL database practice, is there a standard ADD command used to insert one row or to add multiple rows from a query result, or is row insertion performed by another statement (such as INSERT and INSERT ... SELECT)?

Difficulty: Easy

Correct Answer: Incorrect

Explanation:


Introduction / Context:
SQL provides well-defined statements for data manipulation. This item tests whether the statement “ADD command inserts one row or many rows from a query” reflects standard SQL terminology and behavior across common database systems.



Given Data / Assumptions:

  • The claim is that an ADD command inserts rows.
  • We consider mainstream SQL implementations (PostgreSQL, MySQL, SQL Server, Oracle).
  • We focus on row insertion versus schema changes.


Concept / Approach:
The SQL statement for inserting data is INSERT. It supports inserting a single row (INSERT INTO ... VALUES (...)) or multiple rows either via multiple VALUES clauses or by selecting from another result set (INSERT INTO ... SELECT ...). The keyword ADD is not a DML verb for rows; rather, ADD typically appears in ALTER TABLE to add a column, constraint, or index, depending on the DBMS dialect.



Step-by-Step Solution:

Identify the required action: insert data rows.Recall standard SQL: INSERT is the correct statement for row insertion.Check multi-row support: INSERT ... SELECT and multi-VALUES provide bulk insertion.Map ADD correctly: used in ALTER TABLE contexts, not for inserting rows.


Verification / Alternative check:
Try example patterns: INSERT INTO t(col1,col2) VALUES (1, 'a');INSERT INTO t(col1,col2) SELECT colA,colB FROM u; Both are valid; there is no “ADD INTO” for rows in standard SQL.



Why Other Options Are Wrong:

  • “Correct” would endorse a non-standard statement.
  • “Vendor-specific” is misleading; major DBMSs do not use ADD to insert rows.
  • “Valid only inside stored procedures” is irrelevant; INSERT works both inside and outside procedures.
  • “Applies only to adding columns” is a partial truth about ADD, but the prompt is about inserting rows.


Common Pitfalls:
Confusing DML (INSERT) with DDL ALTER TABLE ... ADD. Remember that adding rows uses INSERT; adding columns or constraints may use ADD.



Final Answer:
Incorrect

More Questions from Introduction to SQL

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion