Gyulay Gabor wrote: > The problem is that I need to store numbers with lot more > than 16 decimal digits - e.g. 1234567890123456789012345.12 > [...]
> The reason is why we need this that there're several > currencies (like italian lire) which requires this kind of > precision. Excellent answer from Carl. Generally, you don't want to store currencies in floating point, anyway, and it's unfortunate that MySQL implements DECIMAL as floating point rather than a variable-length BCD (which is exact). However, I tried a sanity check on that number: taking a value of the order of 100 trillion (say, US dollars - this would be of the order of 50x the amount of the current US annual budget), converting it to, say, Turkish Lire (150000x), I get a number that barely exceeds the signed 64-bit limit, and definitely fits in an unsigned 64-bit number. For Italian lire, the number is a hundred times smaller, and should be well within reach of 64-bit computation. Are you absolutely *sure* you can't stick to a 64-bit number? Are you really dealing with hundreds of quadrillions of US dollars? -- Shankar. --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php