Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-06 Thread Bruce Momjian
Tom Lane wrote: > "John D. Burger" <[EMAIL PROTECTED]> writes: > > Tom Lane wrote: > >> Hm ... between that, the possible crypto connection, and John's > >> personal testimony > > > Just to be clear, this John has yet to use NUMERIC for any > > calculations, let alone in that range. > > My mist

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-06 Thread Tom Lane
"John D. Burger" <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Hm ... between that, the possible crypto connection, and John's >> personal testimony > Just to be clear, this John has yet to use NUMERIC for any > calculations, let alone in that range. My mistake, got confused as to who had sa

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-06 Thread John D. Burger
Tom Lane wrote: Hm ... between that, the possible crypto connection, and John's personal testimony that he actually uses PG for calculations in this range, I'm starting to lean to the idea that we shouldn't cut the range. Just to be clear, this John has yet to use NUMERIC for any calculation

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-05 Thread Tom Lane
Michael Fuhr <[EMAIL PROTECTED]> writes: > On Mon, Dec 05, 2005 at 11:59:10PM -0500, Bruce Momjian wrote: >> Tom Lane wrote: >>> The question remains, though, is this computational range good for >>> anything except demos? >> >> I can say that the extended range is good for finding *printf problem

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-05 Thread Michael Fuhr
On Mon, Dec 05, 2005 at 11:59:10PM -0500, Bruce Momjian wrote: > Tom Lane wrote: > > It looks like the limit would be about factorial(256). > > > > The question remains, though, is this computational range good for > > anything except demos? > > I can say that the extended range is good for findi

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508

2005-12-05 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian writes: > > The limit seems to be around 150k digits: > > It's exactly 10^(128K), as I've mentioned more than once. > > > So, with the patch, the storage length is going from 1000 digits to 508, > > but the computational length is reduced from around 150k digits t

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508 digits

2005-12-05 Thread Gregory Maxwell
On 12/5/05, Tom Lane <[EMAIL PROTECTED]> wrote: > > Not only does 4000! not work, but 400! doesn't even work. I just lost > > demo "wow" factor points! > > It looks like the limit would be about factorial(256). > > The question remains, though, is this computational range good for > anything excep

Re: [HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508 digits

2005-12-05 Thread Tom Lane
Bruce Momjian writes: > The limit seems to be around 150k digits: It's exactly 10^(128K), as I've mentioned more than once. > So, with the patch, the storage length is going from 1000 digits to 508, > but the computational length is reduced from around 150k digits to 508. > Now, because no one

[HACKERS] Reduce NUMERIC size by 2 bytes, reduce max length to 508 digits

2005-12-05 Thread Bruce Momjian
[ Moved to hackers for patch discussion.] John D. Burger wrote: > >> There are practical applications, eg, 1024-bit keys are fairly common > >> objects in cryptography these days, and that equates to about 10^308. > >> I don't really foresee anyone trying to run crypto algorithms with SQL > >> NU