User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the MySQL section within the Web Development category of DaniWeb, a massive community of 391,948 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,884 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our MySQL advertiser:
Views: 5634 | Replies: 2
Reply
Join Date: Jul 2005
Posts: 41
Reputation: ohgosh is an unknown quantity at this point 
Rep Power: 4
Solved Threads: 0
ohgosh's Avatar
ohgosh ohgosh is offline Offline
Light Poster

can i select the 2nd row/record from a table

  #1  
Sep 15th, 2005
Hi peeps...

A good day to all of you yea~ as i know, i can retrieve only the first row by using the keyword limit 1:
select * from tblTesting limit 1
for selecting the first two rows are:
select * from tblTesting limit 2

is there any solution to getting the second row? not the two rows but is second..

THANKS yea~
cheers,
ohgosh
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Jun 2005
Posts: 33
Reputation: comprookie2000 is an unknown quantity at this point 
Rep Power: 4
Solved Threads: 3
comprookie2000's Avatar
comprookie2000 comprookie2000 is offline Offline
Light Poster

Re: can i select the 2nd row/record from a table

  #2  
Sep 16th, 2005
See if this helps, go down about halfway where he is working on tables etc. The first part is setting it up for gentoo but on down a little may be what you want.
http://www.gentoo.org/doc/en/mysql-howto.xml
Reply With Quote  
Join Date: Aug 2005
Location: Oklahoma
Posts: 902
Reputation: chrisbliss18 is an unknown quantity at this point 
Rep Power: 4
Solved Threads: 21
chrisbliss18's Avatar
chrisbliss18 chrisbliss18 is offline Offline
Posting Shark

Re: can i select the 2nd row/record from a table

  #3  
Sep 16th, 2005
The LIMIT directive can take one or two attributes. If you use one attribute, for example "LIMIT 5", it will show only that many records which get taken off of the top of the list of results. If you use two attributes, for example "LIMIT 10, 5", it will skip the number of records indicated by the first number and then show the number of records indicated by the second number. In other words it's "LIMIT skip, show". So to do what you want, execute:
SELECT * FROM tblTesting LIMIT 1, 1
Did we help you? Did we miss the point entirely? Update your thread and let us know.
Don't like the answers you are getting?
Did you try searching?
Clean up and optimize Windows 2000/XP
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb MySQL Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the MySQL Forum

All times are GMT -4. The time now is 8:58 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC