MySQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsDatabasesMySQL Help

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 Dev Shed Forums Sponsor:
  #1  
Old December 17th, 1999, 12:09 PM
pnoren
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
SELECT id, title, genre, price FROM Pictures WHERE title LIKE '% %' ORDER BY title LIMIT 5,10
As I understand it - with the following command I should get the result between 5 and 10 (5 posts) but I get 7 posts!?

Is this a bug or have I missunderstood the use of LIMIT?

When i Use the same query with LIMIT 0,5 I get 5 posts.

Reply With Quote
  #2  
Old December 17th, 1999, 01:21 PM
PhOrPhEr
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
LIMIT 10,5 = Get 5 posts begin from 10.

example:
select * from tb1 limit 10,5;
This will get row nr. 10 to 15

Reply With Quote
  #3  
Old December 18th, 1999, 08:49 AM
rod k
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
IOW, you are requesting 10 rows beginning at 5. If you query only results in 12 matches then you'd get 7 rows.

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesMySQL Help > LIMIT bug?

Developer Shed Advertisers and Affiliates



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 | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap