Start learning 50% faster. Sign in now
The DELETE command in SQL is used to remove specific rows from a table based on a WHERE clause condition. Unlike DROP or TRUNCATE, which impact the entire table, DELETE operates on a more granular level, enabling selective removal of data while preserving the table structure and any other rows. For example: DELETE FROM employees WHERE department = 'Sales'; This query removes only the rows from the employees table where the department is 'Sales', leaving all other rows intact. Additionally, the DELETE command logs each deleted row, making it possible to rollback transactions if the database supports it (e.g., in databases using transaction control). This makes DELETE particularly useful for scenarios where precision and rollback capabilities are required. Explanation of Incorrect Options: A) DROP : The DROP command is used to completely remove a table or database, including its structure. It is not selective and deletes the entire object. B) TRUNCATE : While TRUNCATE removes all rows from a table, it does not allow selective deletion. Furthermore, TRUNCATE is faster but does not log individual row deletions, making rollback impossible in most cases. D) REMOVE : This is not a valid SQL command. E) UPDATE : The UPDATE command is used to modify existing data, not to delete it.
Scientists recently discovered a plant ‘Syntrichia caninervis’ that might be able to survive and grow in the harsh climate of which planet?
Fill in the blank with the most appropriate word.
I ______ an unopened letter lying on the mantelpiece.
What is the base year for the Quick Estimates of IIP (Index of Industrial Production)?
Which organization signed an MoU with the Small Business Administration of the USA?
Which institution forecasted in its Monthly Economic Review for July 2024 that India’s GDP growth would range between 7% and 7.5% for the fiscal year ...
The Reserve Bank of India (RBI) recently appointed who as Executive Director?
Which organization recently enhanced its collaboration with the NSE International Exchange (NSE IX) and National Stock Exchange International Clearing (...
Which country recently approved the schedule for creating its orbital station by 2033?
In which Japanese city was a bust of Mahatma Gandhi unveiled by External Affairs Minister S. Jaishankar?
The Indian Solar Mission Aditya - L1 recently completed its first Halo Orbit around the Sun-Earth L1 Point. Where was this mission designed?