Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread Magnus Hagander
On Wed, Jun 16, 2010 at 05:48, Jayadevan M wrote: > Hello, > >> The EnterpriseDB binaries are not on the community ftp servers, and >> can't be because some of the community servers are in the USA, and those >> USA servers might not block embargoed countries. > Thanks for the clarification. We are

Re: [GENERAL] Ideal Disk recommendation for PostgreSQL

2010-06-15 Thread Scott Marlowe
On Tue, Jun 15, 2010 at 1:48 PM, Bhaskar Sirohi wrote: > Hi All, > > We are right now in initial phase to setup a production server having > PostgreSQL database installed and would require help with Disk > configuration. The database size would grow approx to 500 GB. I have gone > through the foll

Re: [GENERAL] Problem with triggers

2010-06-15 Thread Sid
2010/6/16 Adrian von Bidder > Heyho! > > On Wednesday 16 June 2010 00.56:14 Adrian Klaver wrote: > > > My question is: why do I get information about too long value before > > > trigger fires? > > > Can I change this behavior? > > I firmly feel friendly error messages like this firmly beong into

Re: [GENERAL] Problem with triggers

2010-06-15 Thread Sid
2010/6/16 Tom Lane > Adrian Klaver writes: > > On 06/15/2010 02:01 PM, Sid wrote: > >> I am writing trigger function for validating values inserted into table. > The > >> goal is to print user friendly messages when inserted value is wrong. > > >> My question is: why do I get information about t

Re: [GENERAL] Ideal Disk recommendation for PostgreSQL

2010-06-15 Thread A. Kretschmer
In response to Bhaskar Sirohi : > Hi All, > > We are right now in initial phase to setup a production server having > PostgreSQL database installed and would require help with Disk configuration. > The database size would grow approx to 500 GB. I have gone through the > following link http://momji

Re: [GENERAL] GSS Authentication

2010-06-15 Thread Greig Wise
Nope. I get this: kinit(v5): Client not found in Kerberos database while getting initial credentials On Jun 15, 2010, at 10:03 PM, Bryan Montgomery wrote: > I'm not in front of a linux machine, but does > kinit -kt postgres.keytab -S POSTGRES/host.domain.com grant a ticket without > asking f

Re: [GENERAL] Problem with triggers

2010-06-15 Thread Adrian von Bidder
Heyho! On Wednesday 16 June 2010 00.56:14 Adrian Klaver wrote: > > My question is: why do I get information about too long value before > > trigger fires? > > Can I change this behavior? I firmly feel friendly error messages like this firmly beong into the application and not into the DB. Next

[GENERAL] consequent PQsendQueryPrepared() failed: another command is already in progress

2010-06-15 Thread Anton Maksimenkov
I'm using libpq C Library. I prepared some query and trying to call it many times. But it success only at first time, and then fail with error: ... "another command is already in progress" Here is my testbed: int main (register int const argc, register char *const argv[]) { PGconn

Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread Bruce Momjian
Jayadevan M wrote: > Hello, > > > The EnterpriseDB binaries are not on the community ftp servers, and > > can't be because some of the community servers are in the USA, and those > > USA servers might not block embargoed countries. > Thanks for the clarification. We are in a very early stage of

Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread Jayadevan M
Hello, > The EnterpriseDB binaries are not on the community ftp servers, and > can't be because some of the community servers are in the USA, and those > USA servers might not block embargoed countries. Thanks for the clarification. We are in a very early stage of evaluating EnterpriseDB for our

Re: [GENERAL] Problem with triggers

2010-06-15 Thread Tom Lane
Adrian Klaver writes: > On 06/15/2010 02:01 PM, Sid wrote: >> I am writing trigger function for validating values inserted into table. The >> goal is to print user friendly messages when inserted value is wrong. >> My question is: why do I get information about too long value before trigger >> fi

Re: [GENERAL] Problem with triggers

2010-06-15 Thread Adrian Klaver
On 06/15/2010 02:01 PM, Sid wrote: Hi, I am writing trigger function for validating values inserted into table. The goal is to print user friendly messages when inserted value is wrong. When I check for null values everything works as expected: Inside trigger I have lines: if (new.tvalue is null

Re: [GENERAL] GSS Authentication

2010-06-15 Thread greigwise
I just notice that in your message you had more text further down (regarding the DES encryption). I didn't see that at first. So, I did klist -e as you suggested and I got this: Ticket cache: FILE:/tmp/krb5cc_502 Default principal: u...@domain.com Valid starting Expires Service principal 06

Re: [GENERAL] GSS Authentication

2010-06-15 Thread greigwise
OK. I tried what you suggested. I pasted the whole sequence of commands and the results below. As you can see, the connection to postgres still failed, but it looks like it actually acquired the ticket (I think). What do you make of that? Thanks again for the help. Greig [u...@client ~]$ kd

[GENERAL] Problem with triggers

2010-06-15 Thread Sid
Hi, I am writing trigger function for validating values inserted into table. The goal is to print user friendly messages when inserted value is wrong. When I check for null values everything works as expected: Inside trigger I have lines: if (new.tvalue is null) then RAISE EXCEPTION 'e

[GENERAL] Ideal Disk recommendation for PostgreSQL

2010-06-15 Thread Bhaskar Sirohi
Hi All, We are right now in initial phase to setup a production server having PostgreSQL database installed and would require help with Disk configuration. The database size would grow approx to 500 GB. I have gone through the following link http://momjian.us/main/writings/pgsql/hw_performance/ind

Re: [GENERAL] Backups / replication

2010-06-15 Thread Adrian von Bidder
[continuous backup] On Tuesday 15 June 2010 21.42:52 Oliver Kohll - Mailing Lists wrote: > 1) Continuously ship the WAL records to somewhere on the test server > unknown to Postgres but run the test machine as a normal database > completely separately. If a backup is needed, delete the test databa

Re: [GENERAL] GSS Authentication

2010-06-15 Thread Stephen Frost
* greigw...@comcast.net (greigw...@comcast.net) wrote: > kinit -S POSTGRES/host.domain.com user > > (where user is my account name in AD). That then asked for my password and > when I entered it, it seemed to work. And now klist shows that I have a > ticket. Doing it this way though, the keytab

Re: [GENERAL] How to emulate password generation in PHP with PlpgSQL?

2010-06-15 Thread Josh Kupershmidt
On Sun, Jun 13, 2010 at 8:45 AM, Andre Lopes wrote: > But I'am not getting how to generate the SALT. Can someone give me a clue on > how to do this. The salt() function you posted returns 10 random hexadecimal digits. You could mimic it with something like: SELECT substr(md5(RANDOM()::text), 0,

Re: [GENERAL] Backups / replication

2010-06-15 Thread Alan Hodgson
On Tuesday, June 15, 2010, "Oliver Kohll - Mailing Lists" wrote: > Are either of those two likely? Any other suggestions? Another question > is will the replication coming in v9.0 change things and would it be > worth holding off until then? In particular Command Prompt's PITR tools > look useful

Re: [GENERAL] Inconsistency with LIKE and SIMILAR TO

2010-06-15 Thread Bruce Momjian
Thom Brown wrote: > 2010/6/15 Rosi?ski Krzysztof 2 - Detal TP < > krzysztof.rosins...@telekomunikacja.pl> > > > Hello. > > > > Operators LIKE and SIMILAR TO work differently > > This query works ok.: > > > > SELECT * > > FROM www.test > > WHERE expr like any (ARRAY['a','b']); > > > > But this no

Re: [GENERAL] IMMUTABLE columns in tables?

2010-06-15 Thread Vick Khera
On Tue, Jun 15, 2010 at 11:54 AM, Chris Browne wrote: > I'd like that feature, and I don't think it takes too much arguing to > get to the point that a declarative "IMMUTABLE" control is rather less > Not only that, but if you were to, say, make the PK field IMMUTABLE you could then optimize out

[GENERAL] Backups / replication

2010-06-15 Thread Oliver Kohll - Mailing Lists
Hello, I'm interested in using WAL shipping / replication for backup purposes but have no interest in failover. Currently my situation is: I have two servers, live and backup, which are in different cities. The backup server is also a test/development machine. Backups of my most important data

Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread Vick Khera
On Tue, Jun 15, 2010 at 1:21 AM, M. Bashir Al-Noimi wrote: > So I wish to get a clarification about this issue, does pg forbids my > country? is it still open source? enterprisedb.com != postgres open source project. postgres as far as i know has no restrictions on who may use it anywhere in the

Re: [GENERAL] Inconsistency with LIKE and SIMILAR TO

2010-06-15 Thread Tom Lane
=?iso-8859-2?Q?Rosi=F1ski_Krzysztof_2_-_Detal_TP?= writes: > Operators LIKE and SIMILAR TO work differently Yup. It's an implementation restriction (see the comment for subquery_Op in gram.y if you want to know). regards, tom lane -- Sent via pgsql-general mailing lis

Re: [GENERAL] IMMUTABLE columns in tables?

2010-06-15 Thread Adrian von Bidder
On Tuesday 15 June 2010 18.56:46 Craig Ringer wrote: [IMMUTABLE columns] > Column privs may be bypassed by a superuser To be fair, constraints can be removed via ALTER TABLE, so this is not an argument. For me, the compelling reason to propose this is that it's much more readable than either

Re: [GENERAL] Anyone know about PgMQ?

2010-06-15 Thread Rory Campbell-Lange
OK -- I've spotted another project, AMQP for PostgreSQL. http://lethargy.org/~jesus/writes/amqp-for-postgresql Which looks pretty good. Rory On 11/06/10, Rory Campbell-Lange (r...@campbell-lange.net) wrote: > I was intrigued to see Chris Bohn's page about PgMQ ("Embedding > messaging in PostgreS

Re: [GENERAL] GSS Authentication

2010-06-15 Thread greigwise
As suggested below, I just tried this: kinit -S POSTGRES/host.domain.com user (where user is my account name in AD). That then asked for my password and when I entered it, it seemed to work. And now klist shows that I have a ticket. Doing it this way though, the keytab file doesn't seem to c

Re: [GENERAL] use window as field name in 8.4

2010-06-15 Thread Peter Lee
Well, I guess that's the best solution: change the field name. I hope to find some alternative solution, but I know it won't be easy. Thank you. Peter -Original Message- * Stephen Frost (sfr...@snowman.net) The best solution would probably be to rename those fields in the 8.3 database,

Re: [GENERAL] use window as field name in 8.4

2010-06-15 Thread Steve Crawford
On 06/15/2010 07:58 AM, Peter Lee wrote: I am trying to upgrade our postgresql from 8.3 to 8.4. I found the "window" as field name makes many errors during pg_restore. - like "item.window". Is there any way I can restore the dump file from 8.3 without errors. Peter Does this happen using

Re: [GENERAL] Is there a way to backup Postgres via SQL commands?

2010-06-15 Thread Greg Smith
Dimitri Fontaine wrote: Frank Church writes: Are there SQL commands that can do a backup over a client connection, rather than from the command line like pgsql etc? That's pg_dump ? Dimitri has correctly pointed out the flaw behind the basic assumption being made by asking this

Re: [GENERAL] Disk performance

2010-06-15 Thread Greg Smith
Ivan Voras wrote: (or if you are looking at raw numbers: a 15,000 RPM drive will sustain 15000/60=250 random IOs per second (IOPS) That's only taking into account the rotation speed--a 15K drive can do 250 physical commits per second if you never seek anywhere. A true IOPS number also consid

Re: [GENERAL] use window as field name in 8.4

2010-06-15 Thread Stephen Frost
* Peter Lee (pe...@flairpackaging.com) wrote: > I am trying to upgrade our postgresql from 8.3 to 8.4. > > I found the "window" as field name makes many errors during pg_restore. > > - like "item.window". > > Is there any way I can restore the dump file from 8.3 without errors. The best solutio

[GENERAL] use window as field name in 8.4

2010-06-15 Thread Peter Lee
I am trying to upgrade our postgresql from 8.3 to 8.4. I found the "window" as field name makes many errors during pg_restore. - like "item.window". Is there any way I can restore the dump file from 8.3 without errors. Peter

Re: [GENERAL] Disk performance

2010-06-15 Thread Greg Smith
Janning wrote: IMHO it is looking quite fast compared to the values mentioned in the article. The tests in the article were using the 2006 versions of the same drive you have, so I'd certainly hope yours are faster now. What values do you expect with a very expensive setup like many spind

Re: [GENERAL] Disk performance

2010-06-15 Thread Ivan Voras
On 15 June 2010 18:22, Janning wrote: >> The figures are ok if the tests were done on a single drive (i.e. not >> your RAID-0 array). > > Ahh, I meant raid-1, of course.  Sorry for this. > I tested my raid 1 too and it looks quite the same. Not much difference. This is expected: a RAID-1 array (

Re: [GENERAL] pgcrypto in separate schema

2010-06-15 Thread Magnus Hagander
On Tue, Jun 15, 2010 at 19:02, Brad Nicholson wrote: > I want to put the functions from pgcrypto into a separate schema, but > pgcrypto.sql is explicitly setting the search path to public.  Is there > a reason it does this that I should be aware of? Is it fine to change > that and install the func

[GENERAL] pgcrypto in separate schema

2010-06-15 Thread Brad Nicholson
I want to put the functions from pgcrypto into a separate schema, but pgcrypto.sql is explicitly setting the search path to public. Is there a reason it does this that I should be aware of? Is it fine to change that and install the functions in a separate schema? -- Brad Nicholson 416-673-4106 D

Re: [GENERAL] IMMUTABLE columns in tables?

2010-06-15 Thread Craig Ringer
On 15/06/2010 2:41 AM, Adrian von Bidder wrote: Heyho! (Ok, seems to be feature wish day ...) I was wondering if others would find an IMMUTABLE (or whatever) column constraint useful as well. Semantics would (obviously?) be to disallow changing the value of this column after insert. I realize

Re: [GENERAL] Disk performance

2010-06-15 Thread Alan Hodgson
On Tuesday, June 15, 2010, Janning wrote: > ok, I will look for a hoster who can provide this. Most hosters normaly > offer lots of ram and cpu but no advanced disk configuration. > I've noticed that too, even Rackspace doesn't offer a standard config that anyone would actually want to use for

Re: [GENERAL] Disk performance

2010-06-15 Thread Leonardo F
> thanks very much for your > help. > It gave me a good idea of what to do. If you have further > recommendations, I > would be glad to here them. I guess you should give more info about the expected workload of your server(s)... otherwise you'll risk spend too much money/spend your money in a

Re: [GENERAL] Disk performance

2010-06-15 Thread Janning
On Tuesday 15 June 2010 15:16:19 Ivan Voras wrote: > On 06/15/10 14:59, Janning wrote: > > Hi all, > > > > as we encountered some limitations of our cheap disk setup, I really > > would like to see how cheap they are compared to expensive disk setups. > > > > We have a 12 GB RAM machine with intel

Re: [GENERAL] IMMUTABLE columns in tables?

2010-06-15 Thread Chris Browne
avbid...@fortytwo.ch (Adrian von Bidder) writes: > Heyho! > > (Ok, seems to be feature wish day ...) > > I was wondering if others would find an IMMUTABLE (or whatever) column > constraint useful as well. Semantics would (obviously?) be to disallow > changing the value of this column after inser

[GENERAL] integer to little endian conversion

2010-06-15 Thread maarten
Hi all, I've been looking for a while now to solve my problem. I'd like to store an integer (and other things) in a bytea field of a table from a trigger function. The integer needs to be inserted in it's binary representation: 1 -> \x01\x00\x00\x00 256 -> \x00\x01\x00\x00 (which would be E'\\001

Re: [GENERAL] Inconsistency with LIKE and SIMILAR TO

2010-06-15 Thread Thom Brown
2010/6/15 Rosiński Krzysztof 2 - Detal TP < krzysztof.rosins...@telekomunikacja.pl> > Hello. > > Operators LIKE and SIMILAR TO work differently > This query works ok.: > > SELECT * > FROM www.test > WHERE expr like any (ARRAY['a','b']); > > But this not work: > > SELECT * > FROM www.test > WHE

[GENERAL] Inconsistency with LIKE and SIMILAR TO

2010-06-15 Thread Rosiński Krzysztof 2 - Detal TP
Hello. Operators LIKE and SIMILAR TO work differently This query works ok.: SELECT * FROM www.test WHERE expr like any (ARRAY['a','b']); But this not work: SELECT * FROM www.test WHERE expr similar to any (ARRAY['a','b']); ERROR: syntax error at or near "any" LINE 3: WHERE expr simi

Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread Bruce Momjian
Jayadevan M wrote: > May be you will be able to get one that is not blocked from the ftp sites > list? I don't know if the rules applicable to main server are > automatically applied to the mirror sites too. > http://wwwmaster.postgresql.org/download/mirrors-ftp The EnterpriseDB binaries are not

[GENERAL] Monitoring activities of PostgreSQL

2010-06-15 Thread Allan Kamau
I do have a PL/SQL function that gets executed called many times but with different parameter values each of these times. For most invocations of this function run in a couple of seconds however some invocations of the same function run (on the same dataset) for hours with very little disk activity

Re: [GENERAL] Is there a way to backup Postgres via SQL commands?

2010-06-15 Thread Dimitri Fontaine
Frank Church writes: > Are there SQL commands that can do a backup over a client connection, > rather than from the command line like pgsql etc? That's pg_dump ? > By that I mean some kind of SELECT commands that can retrieve the > database's content as SQL commands that can be replayed to a ser

Re: [GENERAL] Disk performance

2010-06-15 Thread Ivan Voras
On 06/15/10 14:59, Janning wrote: > Hi all, > > as we encountered some limitations of our cheap disk setup, I really would > like to see how cheap they are compared to expensive disk setups. > > We have a 12 GB RAM machine with intel i7-975 and using > 3 disks "Seagate Barracuda 7200.11, ST31500

[GENERAL] pg_restore performance / practicality question

2010-06-15 Thread Mike C
Hi, I want to know if the "pg_restore -a" (data only, no schema) function is a good method to restore data from a backup into an existing database which already has data in its tables (and ensuring that existing data is preserved). I've done a simple test by backing up the database using pg_dump

[GENERAL] Disk performance

2010-06-15 Thread Janning
Hi all, as we encountered some limitations of our cheap disk setup, I really would like to see how cheap they are compared to expensive disk setups. We have a 12 GB RAM machine with intel i7-975 and using 3 disks "Seagate Barracuda 7200.11, ST31500341AS (1.5 GB)" One disk for the system and WAL

Re: [GENERAL] thoughts about constraint trigger

2010-06-15 Thread Adrian von Bidder
On Tuesday 15 June 2010 08.03:49 Craig Ringer wrote: > AFAIK, at this point only FOREIGN KEY constraints may be deferred. I think you didn't understand what I wrote. 9.0 allows to defer UNIQUE as well, but not NOT NULL, which is why I wrote a derred constraint trigger to implement it, which be

Re: [GENERAL] Re: Moving a live production database to different server and postgres release

2010-06-15 Thread Greg Smith
Ulas Albayrak wrote: Unfortunately, the switch to Windows is out of my hands. If it were up to me I'd stick with BSD. When you say postgres on Windows is known for its "mediocre performance", do you mean it's slower or buggy? Or both? Three examples that have varying proportions of slow and

Re: [GENERAL] Re: Moving a live production database to different server and postgres release

2010-06-15 Thread Alban Hertroys
On 15 Jun 2010, at 9:21, Guillaume Lelarge wrote: > Le 15/06/2010 09:18, Ulas Albayrak a écrit : >> Unfortunately, the switch to Windows is out of my hands. If it were up >> to me I'd stick with BSD. When you say postgres on Windows is known >> for its "mediocre performance", do you mean it's slow

Re: [GENERAL] Partial indexes instead of partitions

2010-06-15 Thread Leonardo F
> AFAIU the OP is trying to give the cache a chance of > doing some useful > work by partitioning by time so it's going to be forced to > go to disk > less. Exactly > have you > considered a couple of > "levels" to your hierarchy. Maybe bi-hourly (~15 > million records?) > within the current

Re: [GENERAL] DDL partitioning with insert trigger issue

2010-06-15 Thread Alban Hertroys
On 15 Jun 2010, at 24:46, mark wrote: > Hello, > > I am running PG 8.3. and following the guide found > athttp://www.postgresql.org/docs/current/static/ddl-partitioning.html > > > I have followed the steps outlined here nearly exactly with regards to using > an insert trigger to call a fun

Re: [GENERAL] Silent installer in Windows

2010-06-15 Thread Sachin Srivastava
Use CLI option, --unattendedmodeui none On 6/15/10 1:17 PM, M. Bashir Al-Noimi wrote: Sorry for disturbing. I want to run One-Click completely silent, how I can do it? PS I run the following but it always shows installing progress dialog: postgresql-8.4.4-1-windows --install_runtimes 0 --servi

Re: [GENERAL] Silent installer in Windows

2010-06-15 Thread M. Bashir Al-Noimi
Sorry for disturbing. I want to run One-Click completely silent, how I can do it? PS I run the following but it always shows installing progress dialog: postgresql-8.4.4-1-windows --install_runtimes 0 --servicepassword root --unattendedmodeui minimal --mode unattended --prefix c:\pg-8.4 --datadir

Re: [GENERAL] Re: Moving a live production database to different server and postgres release

2010-06-15 Thread Guillaume Lelarge
Le 15/06/2010 09:18, Ulas Albayrak a écrit : > Unfortunately, the switch to Windows is out of my hands. If it were up > to me I'd stick with BSD. When you say postgres on Windows is known > for its "mediocre performance", do you mean it's slower or buggy? Or > both? > Slower. If it were buggy, it

Re: [GENERAL] Re: Moving a live production database to different server and postgres release

2010-06-15 Thread Ulas Albayrak
Unfortunately, the switch to Windows is out of my hands. If it were up to me I'd stick with BSD. When you say postgres on Windows is known for its "mediocre performance", do you mean it's slower or buggy? Or both? /Ulas On Mon, Jun 14, 2010 at 10:22 PM, Scott Marlowe wrote: > On Mon, Jun 14, 201

Re: [GENERAL] Does enterprisedb.com down?

2010-06-15 Thread M. Bashir Al-Noimi
Thanks All, this thread moved now to another mailing list for discussing this problem with EnterpriseDB folks (Bruce Momjian and others). 2010/6/15 Magnus Hagander > On Tue, Jun 15, 2010 at 07:21, M. Bashir Al-Noimi > wrote: > > On 15/06/2010 06:00 ص, John Gage wrote: > > > > I ran the IP on h