Courseiva
Database SecuritymediumMultiple ChoiceObjective-mapped

DBS-C01 Database Security Practice Question

A company is using Amazon Aurora MySQL-Compatible Edition. The database administrator wants to restrict a specific user to only execute SELECT statements on a specific database. Which SQL command should the administrator use?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

GRANT SELECT ON db_name.* TO 'user'@'%';

The GRANT SELECT ON db_name.* TO 'user'@'%' command grants SELECT privilege on all tables within the specified database to the user. Option A is incorrect because ALTER USER with GRANT OPTION is used to change user attributes or grant the ability to grant privileges, not to directly grant SELECT. Option B is incorrect because CREATE USER only creates a new user without assigning any privileges. Option C is incorrect because REVOKE ALL PRIVILEGES removes all privileges from the user, which is opposite of the desired action.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ALTER USER 'user'@'%' WITH GRANT OPTION;

    Why it's wrong here

    Alters user to allow granting privileges, but does not grant SELECT.

  • CREATE USER 'user'@'%' IDENTIFIED BY 'password';

    Why it's wrong here

    Creates user but does not grant SELECT.

  • REVOKE ALL PRIVILEGES ON db_name.* FROM 'user'@'%';

    Why it's wrong here

    This revokes privileges, does not grant SELECT.

  • GRANT SELECT ON db_name.* TO 'user'@'%';

    Why this is correct

    Grants SELECT on all tables in the database.

About these practice questions

Courseiva writes every DBS-C01 question from scratch — 1,663 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This DBS-C01 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DBS-C01 exam.