Dan Nelson wrote:
If not, you'll probably have to read the records and store them in an
array indexed by minute. Then when you're done reading from mysql,
walk the array from 0 to 59 and write out each element. That way
you're guaranteed 60 output rows.
Eh, did something different. Now I
In the last episode (Dec 28), Ashley M. Kirchner said:
> Chris White wrote:
> >I'd try php here, something like:
>Problem is, PHP doesn't know which record is blank. I select for 60
> records and MySQL returns 55. How is PHP supposed to know which 5 are
> blank?
Mysql doesn't know either.
Chris White wrote:
I'd try php here, something like:
Problem is, PHP doesn't know which record is blank. I select for 60
records and MySQL returns 55. How is PHP supposed to know which 5 are
blank?
--
W | It's not a bug - it's an undocumented feature.
+--
Ashley M. Kirchner wrote:
I'd try php here, something like:
$mins[] = empty($row['the_minute']) ? 'blank value' :
$row['the_minute'];
$temp_f[] = empty($row['avg_temp_f']) ? 'blank value' :
$row['avg_temp_f'];
$temp_c[] = empty($row['avg_temp_c']) ? 'blank value' :
$
Thanks to Chris yesterday, I managed to figure some things out by
myself. Now I'm faced with another problem. Given the same database again:
++---+--+-+---++
| Field | Type | Null | Key | Defau