Thread: Storing prices
View Single Post
Old 11-06-2012, 04:49 AM   PM User | #1
LearningCoder
Regular Coder

 
LearningCoder's Avatar
 
Join Date: Jan 2011
Location: The Pleiades
Posts: 849
Thanks: 67
Thanked 28 Times in 28 Posts
LearningCoder is an unknown quantity at this point
Storing prices

Hi, I wanted to store some prices within a database. I looked into it and believe the correct way is to create a table field of DECIMAL type.

I need to be able to insert prices up to £999.99 Maximum. Not sure if I need to give the 'length/values' column any value or if I just leave it blank.

Noticed people are saying to set it to 'unsigned' also. Not quite sure what I'm doing here....

Appreciate any help you can offer.

Kind regards,

LC.
LearningCoder is offline   Reply With Quote