daily pastebin goal
30%
SHARE
TWEET

Untitled

a guest Jun 14th, 2018 51 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. mysql> CREATE TABLE test (floaty FLOAT(8,2)) engine=InnoDb;
  2. Query OK, 0 rows affected (0.02 sec)
  3.  
  4. mysql> insert into test value(858147.11);
  5. Query OK, 1 row affected (0.01 sec)
  6.  
  7. mysql> SELECT * FROM test;
  8. +-----------+
  9. | floaty    |
  10. +-----------+
  11. | 858147.12 |
  12. +-----------+
  13. 1 row in set (0.00 sec)
  14.    
  15. mysql> CREATE TABLE test (floaty FLOAT(8,2)) engine=InnoDb;
  16. Query OK, 0 rows affected (0.03 sec)
  17.  
  18. mysql> insert into test value(131071.01);
  19. Query OK, 1 row affected (0.01 sec)
  20.  
  21. mysql> insert into test value(131072.01);
  22. Query OK, 1 row affected (0.00 sec)
  23.  
  24. mysql> SELECT * FROM test;
  25. +-----------+
  26. | floaty    |
  27. +-----------+
  28. | 131071.01 |
  29. | 131072.02 |
  30. +-----------+
  31. 2 rows in set (0.00 sec)
  32.  
  33. mysql>
  34.    
  35. CREATE TABLE test (val, DOUBLE);
  36.    
  37. CREATE TABLE test (val, DECIMAL(8,2));
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top