Re: [GENERAL] Getting char * from timestamp in a composite type

2007-12-20 Thread Michael Akinde
Thanks, though that was an error caused by my attempt to copy-paste some readable example of code from the source file. Matching the correct _out functions in the DirectFunctionCall fixed the segmentation fault problems I was seeing. Regards, Michael A. Tom Lane wrote: Michael Akinde <[EMA

Re: [GENERAL] Trouble running PostgreSQL server / Server must be started under certain locale.

2007-12-20 Thread Richard Huxton
Geoff Ellingwood wrote: I think my best bet is going to be to nuke my 8.1 installation from orbit (after making a backup of the cluster directory) and let Ubuntu configure it correctly with whatever locale managed to squeeze itself into my system. That's not the problem, the problem is that th

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Andrew Nesheret wrote: Richard Huxton wrote: Andrew Nesheret wrote: Richard Huxton wrote: If you PREPARE then EXECUTE the same query, does it still use the index? Tested, comments? --- code - --- result --- Result for node #2007 Index Scan using fki_nodes on sf_ipv4traffic x (co

Re: [GENERAL] Composite types for composite primary/foreign keys?

2007-12-20 Thread Wolfgang Keller
Hello, and thanks again for your reply. And excuse me for taking so long to reply. I wanted to simplify the schema and make it more "readable" for clueless morons like me. >;-> Simplifying the schema is fine (and good!) as long as it exhibits the same behavior as the more complex one: Wel

[GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Hi all, I don't understand the last result: select 'Ho Ho Ho' ~* '^Ho'; returns true select 'Ho Ho Ho' ~* ' Ho'; returns true select 'Ho Ho Ho' ~* '[^ ]Ho'; returns false (Please note there is a space between ^ and ]) From my limited experience of regex, the last one is searching for either

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Florian Aumeier
hi select 'Ho Ho Ho' ~* '^Ho'; returns true select 'Ho Ho Ho' ~* ' Ho'; returns true select 'Ho Ho Ho' ~* '[^ ]Ho'; returns false (Please note there is a space between ^ and ]) "A /bracket expression/ is a list of characters enclosed in []. It normally matches any single character from the li

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Richard Huxton
Howard Cole wrote: Hi all, I don't understand the last result: select 'Ho Ho Ho' ~* '^Ho'; returns true select 'Ho Ho Ho' ~* ' Ho'; returns true select 'Ho Ho Ho' ~* '[^ ]Ho'; returns false (Please note there is a space between ^ and ]) From my limited experience of regex, the last one is s

Re: [GENERAL] Problem with collector statistic

2007-12-20 Thread Marco Aurélio V . da Silva
Dear, Thanks, this solved my problem. I was using very low values for effective_cache_size. Thanks for your attention, Marco Aurélio V. da Silva Prodata Inf. e Cad. Ltda. MSN: [EMAIL PROTECTED] Fone: (33) 3322-3082 - Original Message - From: "Scott Marlowe" <[EMAIL PROTECTED]> To: "

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Ivan Sergio Borgonovo
On Thu, 20 Dec 2007 09:56:00 + Howard Cole <[EMAIL PROTECTED]> wrote: > Hi all, > > I don't understand the last result: > > select 'Ho Ho Ho' ~* '^Ho'; returns true There is actualli a Ho at the beginning of the string. > select 'Ho Ho Ho' ~* ' Ho'; returns true There are actually 2 ' Ho'

Re: [GENERAL] INDEX on a composite type

2007-12-20 Thread Martijn van Oosterhout
On Wed, Dec 19, 2007 at 10:41:36PM +0100, GMail wrote: > By the way, why not allowing the declaration of an index over a composite > type as a whole? (As opposed to a composite type as the list of single > component types). It would probably work if there was an operator class defined for your typ

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Richard Huxton wrote: Howard Cole wrote: Hi all, I don't understand the last result: select 'Ho Ho Ho' ~* '^Ho'; returns true select 'Ho Ho Ho' ~* ' Ho'; returns true select 'Ho Ho Ho' ~* '[^ ]Ho'; returns false (Please note there is a space between ^ and ]) From my limited experience of r

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread A. Kretschmer
am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: > Your expression works fine Richard, as does '(^| )ho', but can you tell > me why '[ ^]ho' doesn't work? With ^ you means an anchor, but within the brackets it's a simple char. Andreas -- Andreas Kretschmer Kontakt: Hey

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Florian, Richard, Ivan. Fantastic response thank you very much. ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Martijn van Oosterhout
On Thu, Dec 20, 2007 at 11:51:34AM +0100, A. Kretschmer wrote: > am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: > > Your expression works fine Richard, as does '(^| )ho', but can you tell > > me why '[ ^]ho' doesn't work? > > With ^ you means an anchor, but within the br

Re: [GENERAL] Postgres 8.3 HOT and non-persistent xids

2007-12-20 Thread Karsten Hilbert
On Thu, Dec 20, 2007 at 12:55:02AM -0500, Tom Lane wrote: > "Mike C" <[EMAIL PROTECTED]> writes: > > And for non-persistent transaction ids, the documentation says that > > this is for read-only transactions. What defines a read-only > > transaction for this purpose? > > A transaction that has no

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Richard Huxton
Martijn van Oosterhout wrote: On Thu, Dec 20, 2007 at 11:51:34AM +0100, A. Kretschmer wrote: am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: Your expression works fine Richard, as does '(^| )ho', but can you tell me why '[ ^]ho' doesn't work? With ^ you means an anchor

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Andrew Nesheret
Richard Huxton wrote: Since you are getting different plans, this can't be a planned query. Just try feeding a text-file with some SQL PREPARE/EXECUTEs to psql - you can EXPLAIN ANALYSE EXECUTE ... Test 1. with set enable_seqscan to on; set enable_seqscan to on; prepare testStatement (int) a

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread A. Kretschmer
am Thu, dem 20.12.2007, um 12:03:57 +0100 mailte Martijn van Oosterhout folgendes: > On Thu, Dec 20, 2007 at 11:51:34AM +0100, A. Kretschmer wrote: > > am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: > > > Your expression works fine Richard, as does '(^| )ho', but can you

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Martijn van Oosterhout wrote: On Thu, Dec 20, 2007 at 11:51:34AM +0100, A. Kretschmer wrote: am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: Your expression works fine Richard, as does '(^| )ho', but can you tell me why '[ ^]ho' doesn't work? With ^ you

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Howard Cole wrote: Martijn van Oosterhout wrote: On Thu, Dec 20, 2007 at 11:51:34AM +0100, A. Kretschmer wrote: am Thu, dem 20.12.2007, um 10:36:08 + mailte Howard Cole folgendes: Your expression works fine Richard, as does '(^| )ho', but can you tell me why '[ ^]ho' doesn't work?

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Andrew Nesheret wrote: set enable_seqscan to on; prepare testStatement (int) as SELECT 1 FROM ONLY sf_ipv4traffic x WHERE $1 OPERATOR(pg_catalog.=) node FOR SHARE OF x; EXPLAIN ANALYZE execute testStatement( 2007 ); EXPLAIN ANALYZE execute testStatement( 156 );

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Terry Fielder
Howard Cole wrote: Hi Marijn, Andreas, I think Andreas is right, note the ordering of characters in the above example as [ ^] rather than [^ ]. So if the '^' is taken as literal '^', can I check for the beginning of a string in the brackets, Why do you need to? Check for the beginning o

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Howard Cole
Terry Fielder wrote: Why do you need to? Check for the beginning of the string BEFORE the set brackets. The point of set brackets is "match from a set of chars". Since "beginning of string" can only match one place, it has no meaning as a member of a set. Or in other words, if it has meani

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Richard Huxton wrote: I'm putting together a small test case to see if I can reproduce your behaviour here. Does the attached small script misbehave in the same way as your real data? From here it works fine when the fkey is ON ... RESTRICT. I'm right in thinking that your "nodes" fkey is

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Andrew Nesheret
Richard Huxton wrote: Does the attached small script misbehave in the same way as your real data? From here it works fine when the fkey is ON ... RESTRICT. I'm right in thinking that your "nodes" fkey is RESTRICT on update and delete? Yes, data is real and my my foreign key contraint is "res

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Andrew Nesheret wrote: Richard Huxton wrote: Does the attached small script misbehave in the same way as your real data? From here it works fine when the fkey is ON ... RESTRICT. I'm right in thinking that your "nodes" fkey is RESTRICT on update and delete? Yes, data is real and my my forei

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Andrew Nesheret
Richard Huxton wrote: Richard Huxton wrote: I'm putting together a small test case to see if I can reproduce your behaviour here. Does the attached small script misbehave in the same way as your real data? From here it works fine when the fkey is ON ... RESTRICT. I'm right in thinking tha

Re: [GENERAL] Quick Regex Question

2007-12-20 Thread Alvaro Herrera
Howard Cole wrote: > Hmm. Still think they are crazy - sometimes the characters are interpreted > as literals - other times not? Thats crazy in my book! Yeah. ^, like a lot of other chars, means different things when at the beggining of a [] (where it means "negate the character class") than an

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Andrew Nesheret wrote: Richard Huxton wrote: Richard Huxton wrote: I'm putting together a small test case to see if I can reproduce your behaviour here. Does the attached small script misbehave in the same way as your real data? From here it works fine when the fkey is ON ... RESTRICT. I

[GENERAL] Slony I - removing a replication set

2007-12-20 Thread Glyn Astill
Hi people, (I'm not sure how you lot feel about cross posting, but I've posted this on the slony lists as well as here) I setup a slony replication set for a table and subscribed my a node to it. However in the slony log the subscriber shows : 2007-12-20 11:50:38 GMT ERROR remoteWorkerThread_1:

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Ivan Sergio Borgonovo
On Wed, 19 Dec 2007 17:24:52 +0100 Ivan Sergio Borgonovo <[EMAIL PROTECTED]> wrote: > I've something like this: > > create table i ( > iid serial primary key, > name varchar(32) > ); > create table p ( > pid serial primary key, > iid int references i(iid) on delete cascade

[GENERAL] Postgres from PHP in Leopard

2007-12-20 Thread Gordon
I'm a web developer who does a lot of work in PHP. The back end database we use is bases on Postgres. I am trying to set my new MacBook Pro up as a development system. I have managed to install Postgres from http://sourceforge.net/projects/pgsqlformac/ and can access the database on my mac with

Re: [GENERAL] mssql migration and boolean to integer problems

2007-12-20 Thread robert lazarski
On Dec 17, 2007 12:24 PM, Tom Lane <[EMAIL PROTECTED]> wrote: > "robert lazarski" <[EMAIL PROTECTED]> writes: > > Is there any way to get the above insert to work as is, via a function > > or some other way? I tried the function of another poster but it seems > > there is already a cast built in fo

[GENERAL]

2007-12-20 Thread Marcin
Did anybody face the same problem during the compilation of postgresql 8.2.5 on suse 10.2? I'm using gmake 3.81 gcc -I../../include -I../../../../../src/interfaces/ecpg/include -I../../../../../src/interfaces/libpq -I../../../../../src/include -D_GNU_SOURCE -O2 -Wall -Wmissing-prototypes -Wp

Re: [GENERAL] postgres8.3beta encodding problem?

2007-12-20 Thread Tom Lane
Martijn van Oosterhout <[EMAIL PROTECTED]> writes: > It does seem to be a bit wierd. For single character encodings anything > up to 255 is OK, well, sort of. It depends on what you want chr() to do > (oh no, not this discussion again). If you subscribe to the idea that > it should use unicode code

[GENERAL] Trigger in partitioned table

2007-12-20 Thread Goboxe
Hi, When adding sets of new child tables to a artitioned table, I need to update the triggers with new dates added as new condition. See sample below. My question is, what will happen if the update to the trigger happen at the same time as insert operation to the master table? CREATE OR REPLACE

[GENERAL] pgsql cannot read utf8 files moved from windows correctly!

2007-12-20 Thread bookman bookman
H i, I copied a table in sqlserver2005 to a txt file(There were many chinese words in it).I saved it as a file encoded by ANSI,but I cant open it in ubuntu.I tried GBK,GB18030, UTF8,It just could not be opened. Then I save it in windows with encoding UTF8,then I can open it in ubuntu.I copied

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Andrew Nesheret
Richard Huxton wrote: 1. Try adding another 5 million rows to the test "traffic" table and see if that makes any difference. It shouldn't. Opps. 1. Step drop table testnode cascade; drop table traffic;

[GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread dterrors
In php is there a postgresql version of mysql_real_escape_string() ? ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Partitioned tables & Slony

2007-12-20 Thread Goboxe
Thanks Chris. How do I use *.sh & *.ik files? Goboxe On Dec 19, 12:17 am, Chris Browne <[EMAIL PROTECTED]> wrote: > Goboxe <[EMAIL PROTECTED]> writes: > > What need to be taken care of when replicating data from partitioned > > tables? > > > I have several master tables that are inherited by dat

[GENERAL] Partitioned tables & Slony

2007-12-20 Thread Goboxe
Hi, What need to be taken care of when replicating data from partitioned tables? I have several master tables that are inherited by date either daily, weekly and monthly. How to automate addition of newly created child tables into Slony cluster? Thanks, Goboxe ---(end o

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Erik Jones
On Dec 17, 2007, at 8:37 PM, [EMAIL PROTECTED] wrote: In php is there a postgresql version of mysql_real_escape_string() ? You have both pg_escape_string and pg_escape_bytea available. Erik Jones Software Developer | Emma® [EMAIL PROTECTED] 800.595.4401 or 615.292.5888 615.292.0777 (fax) E

[GENERAL] Change of the data directory on Ubuntu 7.04

2007-12-20 Thread Marek Szczypek
Hi All, I have a question - what is the procedure, to change the default location of the data directory of PostgreSQL database? I would like the data to be stored in /dane/postgresql/data instead of the Ubuntu's default location (/var/lib/postgresql/). Is it enough just to run initdb -D /dane/p

Re: [GENERAL] Postgres from PHP in Leopard

2007-12-20 Thread Richard Huxton
Gordon wrote: I'm a web developer who does a lot of work in PHP. The back end database we use is bases on Postgres. I am trying to set my new MacBook Pro up as a development system. I do a fair bit of PHP+PG on my Mac too. I have managed to install Postgres from http://sourceforge.net/proj

Re: [GENERAL] Change of the data directory on Ubuntu 7.04

2007-12-20 Thread Leonel Nunez
> Hi All, > >I have a question - what is the procedure, to change the default > location of the data directory of PostgreSQL database? I would like > the data to be stored in /dane/postgresql/data instead of the Ubuntu's > default location (/var/lib/postgresql/). Is it enough just to run > init

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Bill Moran
In response to Erik Jones <[EMAIL PROTECTED]>: > > On Dec 17, 2007, at 8:37 PM, [EMAIL PROTECTED] wrote: > > > In php is there a postgresql version of mysql_real_escape_string() ? > > You have both pg_escape_string and pg_escape_bytea available. Is there a mysql_fake_escape_string()? Should P

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Richard Huxton
Andrew Nesheret wrote: Richard Huxton wrote: 1. Try adding another 5 million rows to the test "traffic" table and see if that makes any difference. It shouldn't. Opps. 1. Step [snip re-running of script] ---

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Erik Jones
On Dec 20, 2007, at 8:50 AM, Ivan Sergio Borgonovo wrote: On Wed, 19 Dec 2007 17:24:52 +0100 Ivan Sergio Borgonovo <[EMAIL PROTECTED]> wrote: I've something like this: create table i ( iid serial primary key, name varchar(32) ); create table p ( pid serial primary key

Re: [GENERAL] SuSE gcc segfault compiling pgsql

2007-12-20 Thread Colin Wetherbee
Marcin wrote: Did anybody face the same problem during the compilation of postgresql 8.2.5 on suse 10.2? I'm using gmake 3.81 In the future, please include subjects in your posts. gcc -I../../include -I../../../../../src/interfaces/ecpg/include -I../../../../../src/interfaces/libpq -I../../..

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Erik Jones
On Dec 20, 2007, at 9:46 AM, Bill Moran wrote: In response to Erik Jones <[EMAIL PROTECTED]>: On Dec 17, 2007, at 8:37 PM, [EMAIL PROTECTED] wrote: In php is there a postgresql version of mysql_real_escape_string() ? You have both pg_escape_string and pg_escape_bytea available. Is ther

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Richard Huxton
Bill Moran wrote: In response to Erik Jones <[EMAIL PROTECTED]>: On Dec 17, 2007, at 8:37 PM, [EMAIL PROTECTED] wrote: In php is there a postgresql version of mysql_real_escape_string() ? You have both pg_escape_string and pg_escape_bytea available. Is there a mysql_fake_escape_string()?

Re: [GENERAL] to realise the dark side of Microsoft SQL Server...?

2007-12-20 Thread T.J. Adami
On Dec 19, 4:23 pm, [EMAIL PROTECTED] (Geoffrey) wrote: > Joshua D. Drake wrote: > > Geoffrey wrote: > >> Johan van Zyl wrote: > >>> Please elaborate! (Many a true word spoken in jest) > >>> "That is until I can convince my new employer to realise the dark side > >>> of Microsoft SQL Server." > > >

Re: [GENERAL] Trigger in partitioned table

2007-12-20 Thread Erik Jones
On Dec 18, 2007, at 5:53 AM, Goboxe wrote: Hi, When adding sets of new child tables to a artitioned table, I need to update the triggers with new dates added as new condition. See sample below. My question is, what will happen if the update to the trigger happen at the same time as insert oper

Re: [GENERAL] pgsql cannot read utf8 files moved from windows correctly!

2007-12-20 Thread Martijn van Oosterhout
On Tue, Dec 18, 2007 at 02:53:16PM +0800, bookman bookman wrote: > I know that every line of utf8 files is started with "fffe" or "feff" > and ended with "\r\n" in windows but not in linux,so the character > "1" has a space before it in the error line. Err, no. In UTF-16 files it is common to b

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Ivan Sergio Borgonovo
On Thu, 20 Dec 2007 09:55:29 -0600 Erik Jones <[EMAIL PROTECTED]> wrote: > > On Dec 20, 2007, at 8:50 AM, Ivan Sergio Borgonovo wrote: > > > On Wed, 19 Dec 2007 17:24:52 +0100 > > Ivan Sergio Borgonovo <[EMAIL PROTECTED]> wrote: > > > >> I've something like this: > >> > >> create table i ( > >>

Re: [GENERAL] Postgres 8.3 HOT and non-persistent xids

2007-12-20 Thread Mike C
Thank you both, this clears everything up for me. Cheers, Mike ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Postgres from PHP in Leopard

2007-12-20 Thread John DeSoi
On Dec 19, 2007, at 6:32 AM, Gordon wrote: However, the problem is that I can't get PHP to talk to Postgres. Running phpinfo () on the built in PHP shows that database support extends as MySql, Mysqli and SQLite extensions, and SQLite drivers for PDO. What I really need is a Postgres extension

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Richard Huxton
Ivan Sergio Borgonovo wrote: * i has a default property i.name "he is hungry by default" i.name=hungry * i has a set of other property he can chose from in p (thirsty, happy...) * c is the chosen property of the day (c actually will contain more than a p) c can contain: 1) sorry not chosen yet

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Sam Mason
On Thu, Dec 20, 2007 at 06:31:47PM +0100, Ivan Sergio Borgonovo wrote: > On Thu, 20 Dec 2007 09:55:29 -0600 Erik Jones <[EMAIL PROTECTED]> wrote: > > On Dec 20, 2007, at 8:50 AM, Ivan Sergio Borgonovo wrote: > > > On Wed, 19 Dec 2007 17:24:52 +0100 > > > Ivan Sergio Borgonovo <[EMAIL PROTECTED]> wr

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Sean Z.
BTW, what's the best way to determine the installation folder, port number used by an existing postgres server? From registry HKEY_LOCAL_MACHINE\SOFTWARE\PostgreSQL\Installations ? - Original Message From: Scott Marlowe <[EMAIL PROTECTED]> To: Sean Z. <[EMAIL PROTECTED]> Cc: pgsql-gener

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Sean Z.
Sorry I am not familiar with hyperic. Do you mean I can use hyperic to do the job, or do you mean I can take the same approach as hyperic? - Original Message From: Scott Marlowe <[EMAIL PROTECTED]> To: Sean Z. <[EMAIL PROTECTED]> Cc: pgsql-general@postgresql.org Sent: Wednesday, Decembe

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Dave Page
Sean Z. wrote: > BTW, what's the best way to determine the installation folder, port > number used by an existing postgres server? From registry > HKEY_LOCAL_MACHINE\SOFTWARE\PostgreSQL\Installations ? Yes. From a related doc I once wrote: When PostgreSQL is installed on Windows it adds a number

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread mgainty
Hi Sean take a look at port specification in postgresql.conf $PGDATA/postgresql.conf port = Anyone else? Martin - Original Message - Wrom: JVTLBXFGGM To: Scott Marlowe Cc: pgsql-general@postgresql.org Sent: Thursday, December 20, 2007 3:00 PM Subject: Re: [GENERAL] Deploy

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Harald Armin Massa
> > HKLM\Software\PostgreSQL\Services\\Service Account > > Where: > > [...] > Service account is the Windows user account that the pg_ctl service runs > under, eg. MYPC\postgres > I guess that would be "service account that was assigned to the postgres service during installation", and that that k

Re: [GENERAL] referential integrity and defaults, DB design or trick

2007-12-20 Thread Ivan Sergio Borgonovo
On Thu, 20 Dec 2007 17:53:23 + Richard Huxton <[EMAIL PROTECTED]> wrote: > CREATE TABLE properties ( >pid serial, >name text, >PRIMARY KEY (pid) > ); > CREATE TABLE user_default_property ( >uid int NOT NULL REFERENCES users, >pid int NOT NULL REFERENCES properties, >PRI

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Dave Page
Harald Armin Massa wrote: > HKLM\Software\PostgreSQL\Services\\Service Account > > Where: > > [...] > Service account is the Windows user account that the pg_ctl service runs > under, eg. MYPC\postgres > > > I guess that would be "service account that was assigned to the pos

Re: [GENERAL]

2007-12-20 Thread Albe Laurenz
Marcin wrote: > Did anybody face the same problem during the compilation of > postgresql 8.2.5 on suse 10.2? I'm using gmake 3.81 > [...] > dynalloc2.pgc:55: internal compiler error: Segmentation fault > Please submit a full bug report, > with preprocessed source if appropriate. [...] Dunno, but

Re: [GENERAL] Deploy postgres - upgrade strategy

2007-12-20 Thread Scott Marlowe
On Dec 20, 2007 2:04 PM, Sean Z. <[EMAIL PROTECTED]> wrote: > > Sorry I am not familiar with hyperic. Do you mean I can use hyperic to do > the job, or do you mean I can take the same approach as hyperic? I mean you can take the same approach as them. ---(end of broadcast

Re: [GENERAL] Your opinion about PostgreSQL?

2007-12-20 Thread Ron Mayer
Cindy Parker wrote: > ...choice of Oracle or PostgreSQL for the back-end... > Can you help me compare PostgreSQL to SQL Server and/or Oracle? Do > you know of any websites or blogs that discuss these issues? ... > I did look at http://sql-info.de/postgresql/postgres-gotchas.html, an > excellent pa

Re: [GENERAL]

2007-12-20 Thread Colin Wetherbee
Albe Laurenz wrote: Marcin wrote: Did anybody face the same problem during the compilation of postgresql 8.2.5 on suse 10.2? I'm using gmake 3.81 [...] dynalloc2.pgc:55: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. [..

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Kevin Hunter
At 10:46a -0500 on 20 Dec 2007, Bill Moran wrote: > In response to Erik Jones <[EMAIL PROTECTED]>: >>> In php is there a postgresql version of mysql_real_escape_string() ? >> You have both pg_escape_string and pg_escape_bytea available. > > Is there a mysql_fake_escape_string()? Should PostgreSQL

[GENERAL] Howto backup all functions?

2007-12-20 Thread Ow Mun Heng
Hi, is there a simple way for me to backup all the functions which I've written for a server? Thanks ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread brian
Kevin Hunter wrote: In response to Erik Jones <[EMAIL PROTECTED]>: In php is there a postgresql version of mysql_real_escape_string() ? Serious now, who writes the code for those PHP functions? Is that a call that PHP makes to the respective database or does someone actually continually ke

Re: [GENERAL] Howto backup all functions?

2007-12-20 Thread brian
Ow Mun Heng wrote: Hi, is there a simple way for me to backup all the functions which I've written for a server? pg_dump -s will output the schema only (which includes all of your defined functions). brian ---(end of broadcast)--- TIP 6: exp

Re: [GENERAL] Is there PHP mysql_real_escape_string for postgresql?

2007-12-20 Thread Merlin Moncure
On Dec 17, 2007 9:37 PM, <[EMAIL PROTECTED]> wrote: > In php is there a postgresql version of mysql_real_escape_string() ? There is (mentioned upthread), but if you are writing C vs. libpq you may want to take a look a the parameterized interface. It's a little raw but parameterized queries do n

Re: [GENERAL] Composite types for composite primary/foreign keys?

2007-12-20 Thread Merlin Moncure
On Dec 20, 2007 4:40 AM, Wolfgang Keller <[EMAIL PROTECTED]> wrote: > I'm not sure whether I am violating some copyright, so I didn't want to > post the SQL script here. But the script is publicly downloadable at > www.mimosa.org, and I only need a part of it to explain the basic > concept. So this

Re: [GENERAL] foreign key constraint, planner ignore index.

2007-12-20 Thread Andrew Nesheret
Richard Huxton wrote: Hmm - not seeing that here. Is it just that your machine has a very variable workload? The times above are far enough apart from the times below that I'm not sure they can be trusted. What if you run it 10 times - do the times stay consistent? stay consistent and this tes