Re: [SQL] VACUUM not doing its job?

2002-08-03 Thread Ken Corey
I've run into this myself. Tom lane helped me out. In my case, it was the fact that indexes don't release the space of indexes of deleted rows. So, if you have a table that has a lot of inserts/deletes, your indexes will grow incredibly fast. The way to see what your biggest items are: selec

Re: [SQL] Returning PK of first insert for second insert use.

2002-08-02 Thread Ken Corey
turns 17. That means that unless the results of process B depend in some way upon the results of process A, there's no problem. -Ken -- Ken Corey CTO http://www.atomic-interactive.com 07720 440 731 ---(end of broadcast)

Re: [SQL] Returning PK of first insert for second insert use.

2002-08-02 Thread Ken Corey
VALUES (tempvar,$1, $2); -- Everything has passed, return id as pk RETURN tempvar; END; ' LANGUAGE 'plpgsql'; WARNING: this is not guaranteed to be the correct syntax, I didn't create the tables and the function to test it

[SQL] Re: Re: Using Random Sequence as Key

2001-07-10 Thread Ken Corey
nsert. > > -Josh Berkus > > > > > > > __AGLIO DATABASE SOLUTIONS___ >Josh Berkus > Complete information technology [EMAIL PROTECTED] > and data management solutions (415) 565-7293 >

[SQL] Fwd: Silly question about numbering of rows?

2001-03-13 Thread Ken Corey
from that, but that sounds like much busywork for the database. It sounds easiest to me to just punt and number the rows as they are returned in my calling application... What's the best approach here? -- Ken Corey, CTOAtomic Interactive, Ltd. [EMAIL PROTECTED] ---

[SQL] Silly question about numbering of rows?

2001-03-13 Thread Ken Corey
;s the best approach here? -- Ken Corey, CTOAtomic Interactive, Ltd. [EMAIL PROTECTED] ---(end of broadcast)--- TIP 6: Have you searched our list archives? http://www.postgresql.org/search.mpl

[SQL] My apologies...

2001-02-12 Thread Ken Corey
My apologies to the lists...in trying to stop my own spam, I spammed you all. This has now been fixed. Again, sorry for any inconvenience. -Ken

[SQL] Transactions in PLPGSQL?

2001-02-06 Thread Ken Corey
Hi All! Are the BEGIN/END; seen in a typical PL/PGSQL function a transaction wrapper, or do I need to add another BEGIN/END block? Should I just put a 'rollback' in the function, or do I need to do something special? Thanks! -Ken

Re: [SQL] Hrm...why is this wrong?

2001-02-04 Thread Ken Corey
Wow! Answering emails on a Sunday? Someone should be giving you an award or something. On Sunday 04 February 2001 8:13 pm, you wrote: > Ken Corey <[EMAIL PROTECTED]> writes: > > When the select at the bottom of this email is executed, I'm getting the > > message:

[SQL] Hrm...why is this wrong?

2001-02-04 Thread Ken Corey
In trying to use a plpgsql stored proc, I'm getting an error I don't understand. When the select at the bottom of this email is executed, I'm getting the message: ERROR: parser: parse error at or near "$1" Any ideas? -- Ken Corey, CTOAtomic Interactive, Lt

[SQL] Re: binary operators

2001-01-30 Thread Ken Corey
Frederic Metoz wrote: > I am looking for the binary AND and OR ... SHIFT as well. > Do they exist for postgresql ? Depending on what you're doing...you might get away with using mathematical operators to accomplish the above... A right SHIFT would be dividing by 2. A left shift would be multipl

[SQL] Re: Help with query. (*)

2001-01-17 Thread Ken Corey
[NOTE: I'm a pgsql newbie myself. Take this reply with a large-ish grain of salt!) Shouldn't it be something straightforward like: select a.a, a.b, a.c, ... from a a, b b where a.x = b.x, and a.y = b.y, ... (I'd watch out for too many clauses here...