Mysql Row Counts [Resolved]
Posted: Fri Aug 30, 2013 7:18 pm
Okay, I thought I could do a limit 1 to get the first row in the table. It works fine. And then I use a limit 1,2 to get the second row; it works just fine. But when I want to call the third row "limit 2,3" it doesn't work. Is there a reason?
1st Row Works Fine
2nd Row Works Find
3rd Row Displays Information But Will Not Update With New Information
1st Row Works Fine
Code: Select all
$order = "SELECT * FROM locations LIMIT 1";
$result = mysql_query($order);
while ($row=mysql_fetch_array($result)){
echo $row['id'];
echo $row['location'];
echo $row['name'];Code: Select all
$order = "SELECT * FROM locations LIMIT 1,2";
$result = mysql_query($order);
while ($row=mysql_fetch_array($result)){
echo $row['id'];
echo $row['location'];
echo $row['name'];Code: Select all
$order = "SELECT * FROM locations LIMIT 2,3";
$result = mysql_query($order);
while ($row=mysql_fetch_array($result)){
echo $row['id'];
echo $row['location'];
echo $row['name'];