Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialJames Tecco
4,194 PointsOFFSET question - help me understand
--Obtain the actor records between the 701st and 720th records using only LIMIT and OFFSET -- N.B Due to actors being removed from the database the 701st row has the id of 702
SELECT * FROM actors ORDER BY id ASC LIMIT 20 OFFSET 699;
Why is the correct OFFSET 699 and not 700 when I want to obtain the records between 701 & 720?
I originally used 700, but it returned 702-720.
My understanding of OFFSET is that it is the number to skip over.
1 Answer
Mel Rumsey
Treehouse ModeratorHey there James Tecco!
Sorry for the delayed response. It does sound like "700" should be correct in order to skip to record 701... Would you mind sharing the challenge you got this from?