Vitals form temperature field broken

markleeds wrote on Friday, April 21, 2006:

I just realized that all of my temperatures of 100 and above were being set to 99.99.  I tested by trying an insert directly into mysql and it turns out to be most likely due to the type.

It is float (4,2).  Maybe it should be float (4,1) ?

sunsetsystems wrote on Friday, April 21, 2006:

The vitals form had several problem fields like this.  You’ll find corrections for them in cvs, under sql/2_8_0-to-2_8_1_upgrade.sql and sql/2_8_1-to-2_8_2_upgrade.sql.

– Rod
www.sunsetsystems.com

markleeds wrote on Friday, April 21, 2006:

Thanks, I found it.  It’s in sql/2_8_0-to-2_8_1_upgrade.sql:

mysql> ALTER TABLE form_vitals
    ->   MODIFY temperature float(5,2) default 0,
    ->   MODIFY pulse       float(5,2) default 0,
    ->   MODIFY respiration float(5,2) default 0,
    ->   MODIFY waist_circ  float(5,2) default 0;

I hope no one needs numbers that high for respirations and waist_circ!

sunsetsystems wrote on Friday, April 21, 2006:

Perhaps a veterinarian?  :slight_smile:

– Rod
www.sunsetsystems.com