The _______ method in the database/sql package is used to execute a SQL query that returns rows.

  • Exec
  • QueryRow
  • Query
  • Execute
The correct option is "Query". The Query method is used to execute a SQL query that returns rows. It prepares the SQL statement and then executes it, returning a Rows result set for further processing.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *