Re: [SQL] Relation "pg_relcheck"

2003-02-26 Thread Tilo Schwarz
Tom Lane writes: > "Victor Yegorov" <[EMAIL PROTECTED]> writes: > > mema2=> \d forest > > ERROR: Relation "pg_relcheck" does not exist > > > > Whats the problem, I wonder. > > psql version not matching server version. > > regards, tom lane Because this sort of questions appe

[SQL] btree_gist, gint4_union

2003-02-26 Thread Itai Zukerman
In contrib/btree_gist/ I see: CREATE FUNCTION gint4_union(bytea, internal) RETURNS int4 AS 'MODULE_PATHNAME' LANGUAGE 'C'; but gint4_union does this: INT4KEY *out = palloc(sizeof(INT4KEY)); [...] PG_RETURN_POINTER(out); Is the int4 return type declared above a bug? -- Itai Zuker

Re: [SQL] Design Q.:logic in app or db?

2003-02-26 Thread Josh Berkus
George, > I have general design question about Postgres usage: How does one decide > how much, and what parts of logic should go in DB rules, triggers, > functions, constraints etc, versus what should go in the application? Ideally, this should be done strictly on the basis of carefully planned

Re: [SQL] Return type of triger functions from OPAQUE to TRIGGER in 7.3

2003-02-26 Thread Josh Berkus
Roberto, > No, that was not what I was suggesting. I was suggesting (based on my > assumption that 'create function ... returns opaque' would convert the > return type to trigger), that its behaviour be made consistent with > 'create or replace function' and throw an error if the type is opaque.

Re: [SQL] disable constraints

2003-02-26 Thread rute solipa
i whant avoid to dropping constraint, i whant to disable the constraints, because i need to insert a large amont of data. is there a way? best regards, rute At 03:47 PM 2/26/2003 +0100, you wrote: Hi! use "alter table ??? drop constraint ???" example: create table asdf (userid text, foreign

[SQL] Design Q.:logic in app or db?

2003-02-26 Thread george young
I have general design question about Postgres usage: How does one decide how much, and what parts of logic should go in DB rules, triggers, functions, constraints etc, versus what should go in the application? I see postings here from people who obviously have a lot of domain logic in the DB sid

Re: [SQL] disable constraints

2003-02-26 Thread Patrik Kudo
Hi! use "alter table ??? drop constraint ???" example: create table asdf (userid text, foreign key (userid) references person(userid) on delete cascade); \d asdf Table "public.asdf" Column | Type | Modifiers +--+--- userid | text | Foreign Key constraints: $1 FOREIGN

[SQL] disable constraints

2003-02-26 Thread rute solipa
hello, does anyone nows how can i disable/enable table or column constraints? in oracle it's possible to disable constraints like this: alter table tb_1 disable primary key; best regards, rute ---(end of broadcast)--- TIP 3: if posting/reading thro

[SQL] Copy from a SELECT

2003-02-26 Thread val
I know that the COPY command requires that you work with plain tables. Is there any other way at all of export only part of a table ---(end of broadcast)--- TIP 6: Have you searched our list archives? http://archives.postgresql.org