Counting Occurrences within an If statement



I have been working on the something for the last day and can't figure it
out.



I am pulling 7500 rows from a MySQL database, but I only want to display a
certain numbers of rows based up an if statement. I want to count the rows
within the if statement.



mysql query result



if(x < y){

display a row in a table

}else{

Don't display anything

}



Every time a row is displayed, I want to add one to a counter



markb



Relevant Pages

  • Re: large queries
    ... will make SQL queries on a mySQL database that results in very large ... There's a many:many relationship between correspondents and ... populate a JFrame and display it. ... I'm not claimimg this idea (store a minimal list and allow selecting from ...
    (comp.lang.java.databases)
  • Re: Why is this script so slow?
    ... | mysql database that has about 250 records in it. ... | When I use another script to extract the same data and display the ... | I can only conclude it is the script. ...
    (alt.php)
  • Re: Difference between storing files on folder and in mysql db
    ... a separate instance of an image display script (and a separate ... connection to the DB server) to display each image. ... connection if images were stored in the file system. ... mySQL database or if I should just store the files in a dedicated ...
    (comp.lang.php)
  • Re: Help in making links from mysql!
    ... > I have a mysql database with in the database i have ... > How can i display a link with only the title of the document stored?(easy ... You get the five last entries as you have done, ... You query first only the title and the id of the five last entries and ...
    (alt.php)
  • Simple From Generator accessing MySql
    ... I want a simple form generator in PHP that accesses a Mysql database. ... Options for display only, insert new record, and edit. ... I started writing my own, but I am out of time! ...
    (comp.lang.php)