recordset

Tryinging to pull a recordset.

This is what i have:

mysql_select_db($database_wellness, $wellness);
$query_wellnesssessionbcount = “SELECT * FROM sessionb WHERE sessionb.count<30”;
$wellnesssessionbcount = mysql_query($query_wellnesssessionbcount, $wellness) or die(mysql_error());
$row_wellnesssessionbcount = mysql_fetch_assoc($wellnesssessionbcount);
$totalRows_wellnesssessionbcount = mysql_num_rows($wellnesssessionbcount);

which works great but for one of the records i need it to be fore <20 not <30 … is it possible to make an AND statment in there to do that somehow? pertaining to the id of the record possibly?

Thanks!

Can’t you just change the 30 to 20? Using AND will make it <20 only (because 30 is greater than 20).

cant just do that… basically i have around 12 records… 11 needs to show if count < 30 … 1 of the records needs to show if count < 20 … the dymanic data is filling a drop down menu.

Wait, you want to actually show the number of entries that’s below 30 (or 20)? I’m starting to get a bit confused about what this code should actually do now.

Sponsor our Newsletter | Privacy Policy | Terms of Service