$res = sql_select('column', 'table'); if ($res and sql_count($res)>2) { // checks to see if there are at least 3 rows in the results! }