Tag Archives: data type

monetary data: decimal vs. double

Share The DECIMAL and NUMERIC data types are used to store exact numeric data values. In MySQL, NUMERIC is implemented as DECIMAL. These types are used to store values for which it is important to preserve exact precision, for example … Continue reading

Posted in mysql | Tagged , , , , | Leave a comment

Data truncated for column

Share First time I got this error Data truncated for column. I’m using mysql version 5 and I got a simple query like this: $val1= 1; $val2 = 3; INSERT INTO TBL(‘val1′, ‘val2′) VALUES ($val1, $vall2); Notice the variable name … Continue reading

Posted in mysql | Tagged , , , | Leave a comment