[GENERAL] Update links

2013-05-01 Thread C. H. D. for PostgreSQL Questions
Hi! I think there are dead links on this page. http://www.postgresql.org/community/international/ These links cannot be accessed: Chinese (Simplified)     Simplified Chinese PostgreSQL Community Chinese (Traditional)     Traditional Chinese PostgreSQL Community As of 1 May, 2013, I could not o

Re: [GENERAL] Simple SQL INSERT to avoid duplication failed: why?

2013-05-01 Thread Carlo Stonebanks
Very good to know, Steve. We're on 9.0 right now but I will investigate as all the work is for unattended automatic processes which are continuously streaming data from multiple resources and need to resolve these collisions by themselves. -Original Message- From: pgsql-general-ow...@post

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Andrew Hastie
On 30/04/13 20:46, Merlin Moncure wrote: On Tue, Apr 30, 2013 at 12:26 PM, Jeff Janes wrote: On Tue, Apr 30, 2013 at 8:28 AM, Andrew Hastie wrote: I'm currently working on a project porting an application from RedHat Linux on Intel onto IBM zLinux. Our application requires PostgreSQL at vers

[GENERAL] Created a PostgreSQL test, what do you think?

2013-05-01 Thread Jsmarterer
Hey gang, We created a PostgreSQL test for database admins to test their knowledge and prove their skills to employers and members of the community. What do you think? By taking the test and flagging any wonky questions, you'll be helping make the test better for future PostgreSQL users. Check it

Re: [GENERAL] Created a PostgreSQL test, what do you think?

2013-05-01 Thread Andrew Sullivan
On Wed, May 01, 2013 at 07:16:29AM -0700, Jsmarterer wrote: > prove their skills to employers and members of the community. What do you > think? I think that you should not use this list to solicit people to contribute to you free work that you then assert complete control over (http://smarterer.

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Merlin Moncure
On Wed, May 1, 2013 at 8:01 AM, Andrew Hastie wrote: > > On 30/04/13 20:46, Merlin Moncure wrote: >> >> On Tue, Apr 30, 2013 at 12:26 PM, Jeff Janes wrote: >>> >>> On Tue, Apr 30, 2013 at 8:28 AM, Andrew Hastie >>> wrote: I'm currently working on a project porting an application from R

Re: [GENERAL] Created a PostgreSQL test, what do you think?

2013-05-01 Thread Shaun Thomas
On 05/01/2013 09:16 AM, Jsmarterer wrote: Let me know if you have any questions and post your scores below! This test seems out of date and contains arguably incorrect answers. * True or False? PostgreSQL supports Index Only Scans. - The test thinks this is false, but such was added in 9.2.

[GENERAL] LONG delete with LOTS of FK's

2013-05-01 Thread Larry Rosenman
I have an app that we have a number of tables that all have FK relationships with the account table. We did a massive (2900+ account, probably multi-thousand rows) delete from all the tables, and the delete from the account table is taking a lot of time. druckerdb=> select * from pg_stat_act

Re: [GENERAL] LONG delete with LOTS of FK's

2013-05-01 Thread Shaun Thomas
On 05/01/2013 10:17 AM, Larry Rosenman wrote: I have an app that we have a number of tables that all have FK relationships with the account table. OK so far. Referenced by: * Redacted one-billion foreign keys Wow. I really hope every single one of those tables has an index on the lis

Re: [GENERAL] LONG delete with LOTS of FK's

2013-05-01 Thread Larry Rosenman
On 2013-05-01 10:23, Shaun Thomas wrote: On 05/01/2013 10:17 AM, Larry Rosenman wrote: I have an app that we have a number of tables that all have FK relationships with the account table. OK so far. Referenced by: * Redacted one-billion foreign keys Wow. I really hope every single on

Re: [GENERAL] Simple SQL INSERT to avoid duplication failed: why?

2013-05-01 Thread Merlin Moncure
On Wed, May 1, 2013 at 7:16 AM, Carlo Stonebanks wrote: > Very good to know, Steve. We're on 9.0 right now but I will investigate as > all the work is for unattended automatic processes which are continuously > streaming data from multiple resources and need to resolve these collisions > by themse

Re: [GENERAL] OK to put temp tablespace on volatile storage or to omit it from backups?

2013-05-01 Thread Christophe Pettus
On Apr 30, 2013, at 8:13 PM, Tom Lane wrote: > Appears to be sheer blather, or at least not tempered by any thoughts > of whether it'd work in special cases. As the author of that blog post, I'd go with option (b). :) And that lack of tempering was actually the point. The point there was tha

Re: [GENERAL] OK to put temp tablespace on volatile storage or to omit it from backups?

2013-05-01 Thread Christophe Pettus
On Apr 30, 2013, at 11:34 PM, Yang Zhang wrote: > In other words, I guess, I'm asking because of Xof's comment on that blog > post: > > "That’s true if you recreate the PG_ directory in the tablespace; > otherwise, you get the error: > reindexdb: reindexing of database "test" failed: ERROR: cou

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Andrew Hastie
On 01/05/13 15:34, Merlin Moncure wrote: On Wed, May 1, 2013 at 8:01 AM, Andrew Hastie wrote: On 30/04/13 20:46, Merlin Moncure wrote: On Tue, Apr 30, 2013 at 12:26 PM, Jeff Janes wrote: On Tue, Apr 30, 2013 at 8:28 AM, Andrew Hastie wrote: I'm currently working on a project porting an ap

Re: [GENERAL] Simple SQL INSERT to avoid duplication failed: why?

2013-05-01 Thread Carlo Stonebanks
There are no client poolers (unless pgtcl has one I don't know about) so this is unlikely. The trigger is an interesting idea to try if it happens again - I can't keep it for long as it is for a massive cache (used to deflect calls to a web service) and will bloat the logs pretty quickly. I have

Re: [GENERAL] OK to put temp tablespace on volatile storage or to omit it from backups?

2013-05-01 Thread Christophe Pettus
On Apr 30, 2013, at 11:14 PM, Yang Zhang wrote: > Is this the extent of what I can expect, *always*, even if I had run > the proper experiment involving pulling the cord (or at least kill > -9)? I would not count on it. And if it works 100% reliably now, it might not on a future version of Pos

Re: [GENERAL] Simple SQL INSERT to avoid duplication failed: why?

2013-05-01 Thread Steven Schlansker
On May 1, 2013, at 9:36 AM, "Carlo Stonebanks" wrote: > I have to ask myself, is it more likely that I have discovered some PG > anomaly in 9.0 that no one has ever noticed, or that the client has > accidentally launched the process twice and doesn't know it? Given my (admittedly limited) exper

Re: [GENERAL] Save postgresql node to catch only DML except delete queries

2013-05-01 Thread Jerry Sievers
roshan2013 writes: > Hi > > I want to keep one slave node along with our production master server, but > that slave node only accept all the DML except Delete queries. > > Primary purpose of this slave node is to keep all the data inserted to the > primary database and no need to delete any data

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Merlin Moncure
On Wed, May 1, 2013 at 11:34 AM, Andrew Hastie wrote: > > On 01/05/13 15:34, Merlin Moncure wrote: > > On Wed, May 1, 2013 at 8:01 AM, Andrew Hastie wrote: > > On 30/04/13 20:46, Merlin Moncure wrote: > > On Tue, Apr 30, 2013 at 12:26 PM, Jeff Janes wrote: > > On Tue, Apr 30, 2013 at 8:28 AM, An

Re: [GENERAL] Created a PostgreSQL test, what do you think?

2013-05-01 Thread Gavin Flower
On 02/05/13 02:16, Jsmarterer wrote: Hey gang, We created a PostgreSQL test for database admins to test their knowledge and prove their skills to employers and members of the community. What do you think? By taking the test and flagging any wonky questions, you'll be helping make the test better

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Merlin Moncure
On Wed, May 1, 2013 at 1:21 PM, Merlin Moncure wrote: > On Wed, May 1, 2013 at 11:34 AM, Andrew Hastie wrote: >> >> On 01/05/13 15:34, Merlin Moncure wrote: >> >> On Wed, May 1, 2013 at 8:01 AM, Andrew Hastie wrote: >> >> On 30/04/13 20:46, Merlin Moncure wrote: >> >> On Tue, Apr 30, 2013 at 12:

Re: [GENERAL] Simple SQL INSERT to avoid duplication failed: why?

2013-05-01 Thread Gavin Flower
Carlo: Please see note at the bottom... On 02/05/13 04:36, Carlo Stonebanks wrote: There are no client poolers (unless pgtcl has one I don't know about) so this is unlikely. The trigger is an interesting idea to try if it happens again - I can't keep it for long as it is for a massive cache (us

Re: [GENERAL] Created a PostgreSQL test, what do you think?

2013-05-01 Thread Merlin Moncure
On Wed, May 1, 2013 at 9:16 AM, Jsmarterer wrote: > Hey gang, > > We created a PostgreSQL test for database admins to test their knowledge and > prove their skills to employers and members of the community. What do you > think? By taking the test and flagging any wonky questions, you'll be > helpi

[GENERAL] tstzrange with ... 'infinity'] + upper_inf() using 9.2.4

2013-05-01 Thread Ralph Graulich
Hi, > select upper_inf(tsrange('2013-05-01'::timestamp, 'infinity'::timestamp, > '[]')); upper_inf --- f (1 row) As far as I understood the docs, this query should return true, as the upper bound includes 'infinity'? [http://www.postgresql.org/docs/9.2/interactive/functions-range.ht

Re: [GENERAL] tstzrange with ... 'infinity'] + upper_inf() using 9.2.4

2013-05-01 Thread Tom Lane
Ralph Graulich writes: > select upper_inf(tsrange('2013-05-01'::timestamp, 'infinity'::timestamp, > '[]')); > upper_inf > --- > f > (1 row) > As far as I understood the docs, this query should return true, as the upper > bound includes 'infinity'? No, that's the point of the sentenc

Re: [GENERAL] LONG delete with LOTS of FK's

2013-05-01 Thread Tom Lane
Larry Rosenman writes: > On 2013-05-01 10:23, Shaun Thomas wrote: >> Wow. I really hope every single one of those tables has an index on >> the listed column, and it's the same datatype (bigint). Otherwise, >> this is going to take a long, long time. > Yes, all of them have at least one index tha

Re: [GENERAL] zLinux Load Testing Experience

2013-05-01 Thread Tom Lane
Andrew Hastie writes: > Did you confirm that there is a native spinlocks implementation and it is > being used? - I believe so as no errors or warnings logged during the build. > Is there a simple way to check whether spin-locks are running native? All non-ancient versions of PG force you to s

Re: [GENERAL] tstzrange with ... 'infinity'] + upper_inf() using 9.2.4

2013-05-01 Thread Ralph Graulich
> No, that's the point of the sentence about the range mechanisms not > understanding special values of the underlying type. upper_inf tests > for a range with no upper bound, period. It would need some > type-specific special knowledge to do what you're hoping for, and it > has not got that. Go

[GENERAL] MKDIR_P@: Command not found error in regression test

2013-05-01 Thread Karthik GP
Hi - I installed postgres 9.2.2 from source successfully. I then made some minor code changes to learn how to build postgres again. I am on Ubuntu linux version 3.5.0-17.'./configure' and 'make' gave no errors, but while running 'make check', I get the following error: make -C ../backend submake-e

Re: [GENERAL] Basic question on recovery and disk snapshotting

2013-05-01 Thread Jeff Janes
On Saturday, April 27, 2013, Yang Zhang wrote: > On Sat, Apr 27, 2013 at 11:55 AM, Jeff Janes > > > wrote: > > On Sat, Apr 27, 2013 at 10:40 AM, Yang Zhang > > > > wrote: > >> My question really boils down to: if we're interested in using COW > >> snapshotting (a common feature of modern filesys

Re: [GENERAL] MKDIR_P@: Command not found error in regression test

2013-05-01 Thread Tom Lane
Karthik GP writes: > make[1]: MKDIR_P@: Command not found > make[1]: *** [installdirs-local] Error 127 > make[1]: Leaving directory `/home/user/pgsql/pgsql/src' > make: *** [install-src-recurse] Error 2 > make: Leaving directory `/home/user/pgsql/pgsql' > Any clues on what's wrong?? It's very unl

Re: [GENERAL] Basic question on recovery and disk snapshotting

2013-05-01 Thread Yang Zhang
On Wed, May 1, 2013 at 4:56 PM, Jeff Janes wrote: > That brings up another point to consider. If wal level is minimal, then > tables which you bulk load in the same transaction as you created them or > truncated them will not get any WAL records written. (That is the main > reason the WAL verbos

[GENERAL] Confusing comment in xlog.c or am I missing something?

2013-05-01 Thread Amit Langote
I was just going through the xlog.c and I came across following which confused me: Given, src/include/access/xlogdefs.h #define XLogSegsPerFile (((uint32) 0x) / XLogSegSize) #define XLogFileSize(XLogSegsPerFile * XLogSegSize) Also, typedef struct XLogRecPtr { uint32