Category: 06. SQL Delete

  • DELETE JOIN

    This is very commonly asked question that how to delete or update rows using join clause It is not a very easy process, sometimes, we need to update or delete records on the basis of complex WHERE clauses. There are three tables which we use to operate on SQL syntax for DELETE JOIN. These tables…

  • DELETE VIEW

    Before knowing about what is SQL delete view, it is important to know – What is SQL view? A view is a result set of a stored query on the data. The SQL view is a table which does not physically exist. It is only a virtual table. SQL VIEW can be created by a…

  • DELETE DATABASE

    You can easily remove or delete indexes, tables and databases with the DROP statement. The DROP index statement is: Used to delete index in the table DROP INDEX SYNTAX for MS Access: DROP INDEX SYNTAX for MS SQL Server: DROP INDEX syntax for DB2/Oracle: DROP INDEX syntax for MySQL: DROP DATABASE Statement: The drop database…

  • DELETE DUPLICATE ROWS

    If you have got a situation that you have multiple duplicate records in a table, so at the time of fetching records from the table you should be more careful. You make sure that you are fetching unique records instead of fetching duplicate records. To overcome with this problem we use DISTINCT keyword. It is…

  • DELETE ALL ROWS

    The statement SQL DELETE ALL ROWS is used to delete all rows from the table. If you want to delete all the rows from student table the query would be like, Resulting table after using this query: ID STUDENT_NAME ADDRESS

  • DELETE ROW

    Let us take an example of student. Original table: ID STUDENT _NAME ADDRESS 001 AJEET MAURYA GHAZIABAD 002 RAJA KHAN LUCKNOW 003 RAVI MALIK DELHI If you want to delete a student with id 003 from the student_name table, then the SQL DELETE query should be like this: Resulting table after SQL DELETE query: ID…

  • DELETE TABLE

    The DELETE statement is used to delete rows from a table. If you want to remove a specific row from a table you should use WHERE condition. But if you do not specify the WHERE condition it will remove all the rows from the table. There are some more terms similar to DELETE statement like…

  • DELETE

    The SQL DELETE statement is used to delete rows from a table. Generally DELETE statement removes one or more records from a table. SQL DELETE Syntax Let’s see the Syntax for the SQL DELETE statement: Here table_name is the table which has to be deleted. The WHERE clause in SQL DELETE statement is optional here. SQL DELETE Example Let…