SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseSQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old June 4th, 2001, 06:55 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
ROWNUM in SQL-SERVER

<i><b>Originally posted by : Ramesh (ramesh_bhanu@yahoo.com)</b></i><br /><br /><br /> I am trying to select a row number from SQL Server 2000, and do not know SQL<br />select for this. I know Oracle has rownum. What is the SQL version of this?<br /><br />Thanks

Reply With Quote
  #2  
Old June 5th, 2001, 09:55 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
<i><b>Originally posted by : Erick Vils (erick@websoftware.com.br)</b></i><br />In SQL Server or Access databases the where clause rownum <= 50 can be replaced by:<br /><br />select TOP 50 * from table<br /><br /><br />http://www.websoftware.com.br<br /><br />------------<br />Ramesh at 6/4/2001 4:55:29 AM<br /><br /><br /><br /> I am trying to select a row number from SQL Server 2000, and do not know SQL<br />select for this. I know Oracle has rownum. What is the SQL version of this?<br /><br />Thanks

Reply With Quote
  #3  
Old January 30th, 2002, 01:45 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
<i><b>Originally posted by : syed (syedkattuva@yahoo.com)</b></i><br /><br />I want to know, how to use ROWNUM for the following case in SQL Server.<br /><br />For Exam:<br /><br />Table : TEST<br /><br />TESTID TESTNAME<br />------------------------------------------------<br />100 THOMAS ANTONY<br />101 MARK SMITH<br />100 THOMAS ANTONY<br /><br />I have duplicate rows in above case. So i want to delete one duplicate record.<br /><br />In Oracle i will use the following query,<br /><br />SQL> DELETE FROM TEST WHERE TESTID=100 WHERE ROWNUM<=1<br /><br />How to apply the same query in SQL Server..<br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />------------<br />Erick Vils at 6/5/2001 7:55:45 AM<br /><br />In SQL Server or Access databases the where clause rownum <= 50 can be replaced by:<br /><br />select TOP 50 * from table<br /><br /><br />http://www.websoftware.com.br<br /><br />------------<br />Ramesh at 6/4/2001 4:55:29 AM<br /><br /><br /><br /> I am trying to select a row number from SQL Server 2000, and do not know SQL<br />select for this. I know Oracle has rownum. What is the SQL version of this?<br /><br />Thanks

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseSQL Development > ROWNUM in SQL-SERVER


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway