Re: [SQL] showing multiple REFERENCE details of id fields in single query that share the same table

2005-09-14 Thread Thomas O'Connell
On Sep 14, 2005, at 8:11 PM, Ferindo Middleton Jr wrote: I have a table which has two id fields which REFERENCE data back at another table. It's setup like this: class_prerequisite_bindings(id SERIAL, class_id INTEGER REFERENCES classes(id), prerequisiteINTEGER REFERENCES class

Re: [SQL] double precision to numeric overflow error

2003-01-07 Thread Thomas O'Connell
specific scenario (insufficient precision) that generates the error. unfortunately, i haven't read the code... :( -tfo In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Tom Lane) wrote: > "Thomas O'Connell" <[EMAIL PROTECTED]> writes: > > Indeed, it seems as th

Re: [SQL] double precision to numeric overflow error

2003-01-07 Thread Thomas O'Connell
Indeed, it seems as though my inability to count digits was the real problem. Still, does this not strike anyone as a somewhat abstruse error message? -tfo In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Stephan Szabo) wrote: > On Tue, 7 Jan 2003, Thomas O'Connell wrote:

[SQL] double precision to numeric overflow error

2003-01-07 Thread Thomas O'Connell
is this expected behavior? if so, then why? -tfo db=# create table foo( col timestamp ); db=# select cast( extract( epoch from col ) as numeric( 15, 6 ) ) from foo; date_part --- (0 rows) db=# insert into foo values( current_timestamp ); INSERT 1705954 1 db=# select cast( extract( epoc

Re: [SQL] [GENERAL] Bug with sequence

2002-11-21 Thread Thomas O'Connell
It seems worth pointing out, too, that some SQL purists propose not relying on product-specific methods of auto-incrementing. I.e., it is possible to do something like: insert into foo( col, ... ) values( coalesce( ( select max( col ) from foo ), 0 ) + 1, ... ); and this is easily placed in a t