Ver Mensaje Individual
  #5 (permalink)  
Antiguo 21/11/2009, 11:34
Avatar de huesos52
huesos52
Colaborador
 
Fecha de Ingreso: febrero-2009
Ubicación: Manizales - Colombia
Mensajes: 5.980
Antigüedad: 15 años, 2 meses
Puntos: 360
Respuesta: ayuda con campo FLOAT

para visualizar si se puede ayudado de la función round.

Código mysql:
Ver original
  1. mysql> create table e1(campo float);
  2. Query OK, 0 rows affected (0.05 sec)
  3.  
  4. mysql> insert into e1 values(14.00);
  5. Query OK, 1 row affected (0.06 sec)
  6.  
  7. mysql> select *from e1;
  8. +-------+
  9. | campo |
  10. +-------+
  11. |    14 |
  12. +-------+
  13. 1 row in set (0.00 sec)
  14.  
  15. mysql> select round(campo,2) from e1;
  16. +----------------+
  17. | round(campo,2) |
  18. +----------------+
  19. |          14.00 |
  20. +----------------+
  21. 1 row in set (0.05 sec)
  22.  
  23. mysql>
__________________
Without data, You are another person with an opinion.
W. Edwads Deming