About 442,000 results
Open links in new tab
  1. How to delete specific rows in a sql table - Stack Overflow

    Oct 18, 2015 · I am new to SQL and I was looking at the DELETE keyword. I want to know how can I delete multiple rows in one go. Eg I want to delete CategoryID 2,3,5. I am trying DELETE FROM …

  2. sql - Delete duplicate rows keeping the first row - Stack Overflow

    It can be done by many ways in sql server the most simplest way to do so is: Insert the distinct rows from the duplicate rows table to new temporary table. Then delete all the data from duplicate rows …

  3. How to keep only one row of a table, removing duplicate rows?

    I have a table that has a lot of duplicates in the Name column. I'd like to only keep one row for each. The following lists the duplicates, but I don't know how to delete the duplicates and just k...

  4. sql - Delete all rows in a table based on another table - Stack Overflow

    Oftentimes, one wants to delete some records from a table based on criteria in another table. How do you delete from one of those tables without removing the records in both table?

  5. SQL Delete Records within a specific Range - Stack Overflow

    Dec 13, 2016 · This is probably a very simple question for somebody with experience, but I just wanted to know the safest way to delete a couple of hundred records in an SQL table that fall between a …

  6. How to delete multiple rows in SQL where id = (x to y)

    I am trying to run a SQL query to delete rows with id's 163 to 265 in a table I tried this to delete less number of rows DELETE FROM `table` WHERE id IN (264, 265) But when it comes to delete...

  7. sql - How to delete rows in tables that contain foreign keys to other ...

    May 16, 2016 · SQL generally lacks mult-table commands eg a multi insert equivalent that creates rows in the reference and referring tables in a single command would be useful.

  8. ssms - How to delete by row number in SQL - Stack Overflow

    Oct 6, 2017 · Is row_number a column in your table? Are the values 475-948 in that column the rows you want to delete?

  9. T-SQL: Selecting rows to delete via joins - Stack Overflow

    Feb 22, 2016 · I prefer to refer to the table in the first line by its alias. That is "Delete a" rather than "Delete TableA". In the case where you join the table with itself, it makes it clear which side you want …

  10. How do I use cascade delete with SQL Server? - Stack Overflow

    How do I alter the table definitions to perform cascading delete in SQL Server when a record from T1 is deleted, all associated records in T2 also deleted. The foreign constraint is in place between them.