Your Supplied Database
I have added products to your supplied MySQL database
One item is £2.50 per unit
When I log in and change the figure to £2.50 - as soon as I save it - it reverts to £2.5
How can I make the 0 remain visible please
John
I have added products to your supplied MySQL database
One item is £2.50 per unit
When I log in and change the figure to £2.50 - as soon as I save it - it reverts to £2.5
How can I make the 0 remain visible please
John
Here is how you would want to set the data type in the database table:
aa258832(v=SQL.80).aspx
You would want to use decimal(x,2). The x is how many total digits you would need, so something like 6 would most likely be enough for a store. With x as 6, you would be able to store a max of 9999.99 in the column.
I have gone into Localhost and selected the database
I have selected edit on the ProductPrice line
Changed from Float to Decimal and put x,6 in the following line
I get this error code
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'x,6) NOT NULL' at line 1
Help please - I am new to MySQL
You're supposed to replace the x with a number. Please read through the link I provided, which explains it in more detail.
You want something like decimal(6,2) as the type.
Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.
These out-of-the-box solutions provide you proven, tested applications that can be up and running now. Build a store, a gallery, or a web-based email solution.