.Net Tips and Solutions

Friday, June 7, 2013

HOW TO DELETE ROWS FROM A TABLE WITHOUT USING WHERE CONDITION

If we want to delete top 1 row (or) top 2 (or) top 3 (or) top 5 ... etc

We use the query below

Syntax::  Delete top (no. of rows) from <table name>

example:: delete top (2) from tbEmployees

Posted by Surya at 7:43 PM
Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Labels: delete row without using where condition, delete row without using where condition in sql server

No comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Blog Archive

  • ►  2014 (1)
    • ►  February (1)
  • ▼  2013 (33)
    • ►  July (3)
    • ▼  June (8)
      • HOW TO DELETE ROWS FROM A TABLE WITHOUT USING WHER...
      • USE OF LOGGERS IN ASP.NET
      • PURPOSE OF STREAM WRITER IN C#.NET:- StreamWriter...
      • HOW TO COMPARE TWO EXCEL SHEETS AND DISPLAY THE R...
      • Purpose of DateTime.ParseExact Method Converts ...
      • How to convert Numeric values into Roman numbers
      • How to print only the screen without taskbar
      • How to Import data from grid to pdf and excel in V...
    • ►  May (22)
Picture Window theme. Powered by Blogger.