Multiple choice technology databases

You need to remove BUSINESS_HOUR DB trigger.WHich command in SQL*PLUS environmet is used to delete it?

  1. Drop trigger business_hour;

  2. delete trigger business_hour;

  3. remove trigger business_hour;

  4. delete from user_triggers where trigger_name=business_hour;

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The SQL command to delete a trigger is DROP TRIGGER trigger_name;. Option D incorrectly uses DELETE FROM on a system table, which is not the proper way to manage database objects. Options B and C use invalid syntax - DELETE and REMOVE are not standard commands for dropping triggers. The DROP TRIGGER command is the correct DDL statement for permanently removing a trigger from the database.

AI explanation

In SQL*Plus/PL-SQL, the DDL statement to remove any trigger is DROP TRIGGER trigger_name; — there is no DELETE TRIGGER or REMOVE TRIGGER statement in SQL, and DELETE FROM ... operates on table rows, not on schema objects like triggers, so it can't be used to drop one.