List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:February 9 2000 6:17pm
Subject:Re: newbie question about numeric fields
View as plain text  
At 4:12 PM +0200 02-09-2000, Maniac wrote:
>i'm trying to make a simple database where one field is meant for
>numbers only, so I can sort it later by size. the thing is, i'm having
>trouble creating a numeric on decimal field..
>create table test ( size char(20)); works fine, but
>create table test ( size numeric(20)) or
>create table test ( size decimal(20)); don't
>any suggestions?

Check the MySQL manual for the proper syntax.  You'll need to specify the
number of digits after the decimal point, not just the width of the field.
For example numeric(20,4) or decimal (20,3).

Paul DuBois, paul@stripped
newbie question about numeric fieldsManiac9 Feb
  • Re: newbie question about numeric fieldsPaul DuBois9 Feb