[GENERAL] Re: Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Thomas Kellerer
Tim Uckun, 21.10.2010 07:05: No, it isn't. This is a three-way join between consolidated_urls, cu, and tu --- the fact that cu is the same underlying table as cu is an alias for consolidated_urls. tu is an alias for trending_urls. There are only two tables in the query. Yes, but

Re: [GENERAL] postgre on virtual machine

2010-10-21 Thread Craig Ringer
On 21/10/10 05:22, Joshua J. Kugler wrote: On Wednesday 20 October 2010, John R Pierce elucidated thus: On 10/20/10 3:46 AM, Georgi Ivanov wrote: Hi, Is there any specific reason one should/should not run postgre on virtual machine for production ? Is there any special tuning for virtual

Re: [GENERAL] Upgrade from 8.3.3

2010-10-21 Thread Richard Huxton
On 21/10/10 00:04, Rich Shepard wrote: While I'm re-learning how to properly start postgres after a reboot, I'd like recommendations on upgrading my current 8.3.3 to a newer version. Since I'm the only one currently using the system (but I'll be using CMS Made Simple for my revised web site and

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Scott Marlowe
On Wed, Oct 20, 2010 at 11:05 PM, Tim Uckun timuc...@gmail.com wrote: No, it isn't.  This is a three-way join between consolidated_urls, cu, and tu --- the fact that cu is the same underlying table as cu is an alias for consolidated_urls. tu is an alias for trending_urls. There are only two

Re: [GENERAL] Question on Explain : Index Scan

2010-10-21 Thread Mathieu De Zutter
On Thu, Oct 21, 2010 at 3:47 AM, DM dm.a...@gmail.com wrote: I was hoping the optimizer would do a join using index scan. Could some one please explain me why its not doing an index scan rather than sequential scan . A index scan would be probably slower here because you're asking for a lot

Re: [GENERAL] Custom cache implemented in a postgresql C function

2010-10-21 Thread Alban Hertroys
On 21 Oct 2010, at 1:44, Gabi Julien wrote: Hi, Here is my problem: I have a postgresql C function that looks like this: Datum filter(PG_FUNCTION_ARGS); It takes identifiers and queries a bunch of tables and ends up returning true or false. So far nothing difficult except that we want

Re: [GENERAL] 9.0 SSL renegotiation failure restoring data

2010-10-21 Thread Andrus
Uh, we don't ship SSL in the server. We ship code that _uses_ ssl, so I would look at your operating system to see what version of SSL you have, and perhaps update that. I installed postgres 9.0 RC in Windows from official link and looked into bin: Directory of C:\Program

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread Alban Hertroys
On 21 Oct 2010, at 24:28, Raymond O'Donnell wrote: and i'd like to be able to wite a query that would result in 1,A,B 2,A,C 3,A,D [...] PG version is 8.3. Any ideas? You probably want generate_series(): http://www.postgresql.org/docs/8.3/static/functions-srf.html I'm

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread Thomas Kellerer
Alban Hertroys, 21.10.2010 13:43: I'm currently using WebFOCUS at work and they have a LAST operator, referring to the value a column had in the last returned row. That's pretty good for stuff like this, so I wonder if it wouldn't be beneficial to have something like that in Postgres? Already

[GENERAL] GridSQL

2010-10-21 Thread zab08
thanks for share paper of GridSQL or others!

[GENERAL] full vacuum cancelation

2010-10-21 Thread Viktor Bojović
Hi, my full vacuuming of one table runs still after four days. Is it safe to cancel it by pressing Ctrl+c? -- --- Viktor Bojović --- Wherever I go, Murphy goes with me

[GENERAL] Old values in statement triggers?

2010-10-21 Thread Brian Hirt
Is it possible to reference the old values in a statement trigger using plpgsql? I'm looking for something similar to NEW and OLD that row triggers have, but I don' see anything @ http://www.postgresql.org/docs/current/static/plpgsql-trigger.html which doesn't really offer any examples for

Re: [GENERAL] Old values in statement triggers?

2010-10-21 Thread Grzegorz Jaśkiewicz
OLD.column_name NEW.column_name ? -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] 9.0 SSL renegotiation failure restoring data

2010-10-21 Thread Bruce Momjian
Andrus wrote: Uh, we don't ship SSL in the server. We ship code that _uses_ ssl, so I would look at your operating system to see what version of SSL you have, and perhaps update that. I installed postgres 9.0 RC in Windows from official link and looked into bin: Directory of

Re: [GENERAL] Old values in statement triggers?

2010-10-21 Thread Josh Kupershmidt
2010/10/21 Grzegorz Jaśkiewicz gryz...@gmail.com: OLD.column_name NEW.column_name ? I believe OP is asking specifically about statement-level triggers. As the docs http://www.postgresql.org/docs/current/static/trigger-definition.html say: | Statement-level triggers do not currently have any

Re: [GENERAL] a query on stored procedures/functions in pgsql

2010-10-21 Thread Adrian Klaver
On Wednesday 20 October 2010 9:48:39 pm Neil D'Souza wrote: You have same plpgsql identifiers as sql identifiers, and because plpgsql identifiers has higher priority, your query is broken. For simple functions like this don't use a plpgsql language - use sql language instead. Thank you

Re: [GENERAL] 9.0 SSL renegotiation failure restoring data

2010-10-21 Thread Dave Page
On Thu, Oct 21, 2010 at 2:40 PM, Bruce Momjian br...@momjian.us wrote: Andrus wrote: Uh, we don't ship SSL in the server. We ship code that _uses_ ssl, so I would look at your operating system to see what version of SSL you have, and perhaps update that. I installed postgres 9.0 RC in

Re: [GENERAL] postgres services on amazon

2010-10-21 Thread Jos
On Tue, Oct 19, 2010 at 3:35 PM, Aljosa Mohorovic aljosa.mohoro...@gmail.com wrote: i was wondering if anybody is providing postgres services comparable to http://aws.amazon.com/rds/ ? Aljosa Mohorovic I am not aware of anybody offering a postgresql server. But it is very easy to build your

Re: [GENERAL] Old values in statement triggers?

2010-10-21 Thread Brian Hirt
Thanks Josh, On Oct 21, 2010, at 7:49 AM, Josh Kupershmidt wrote: 2010/10/21 Grzegorz Jaśkiewicz gryz...@gmail.com: OLD.column_name NEW.column_name ? I believe OP is asking specifically about statement-level triggers. As Yup. the docs

Re: [GENERAL] postgres services on amazon

2010-10-21 Thread Aljoša Mohorović
On Thu, Oct 21, 2010 at 4:20 PM, Jos rustysc...@gmail.com wrote: I am not aware of anybody offering a postgresql server.  But it is very easy to build your own one.  The advantage is that you can control your own backup schemes. i know, i am using amazon services and have no issues with

Re: [GENERAL] Custom cache implemented in a postgresql C function

2010-10-21 Thread Tom Lane
Alban Hertroys dal...@solfertje.student.utwente.nl writes: That sounds like your function would classify as a STABLE function within Postgres, did you define it as such? Postgres will cache the results of STABLE (and IMMUTABLE) functions all by itself, in which case you may not need your

Re: [GENERAL] full vacuum cancelation

2010-10-21 Thread Tom Lane
=?UTF-8?Q?Viktor_Bojovi=C4=87?= viktor.bojo...@gmail.com writes: my full vacuuming of one table runs still after four days. Is it safe to cancel it by pressing Ctrl+c? I assume this is a pre-9.0 Postgres version? Depending on how far along the vacuum actually is, there's a possibility that

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread David Kerr
On Wed, Oct 20, 2010 at 10:32:15PM -0400, Josh Kupershmidt wrote: - On Wed, Oct 20, 2010 at 6:22 PM, David Kerr d...@mr-paradox.net wrote: - I know I've seen posts on how to do this, but i can't seem to find them. - - I've got a data set - - A, B - A, C - A, D - [...] - - and so on - -

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Richard Broersma
On Wed, Oct 20, 2010 at 7:24 PM, Tim Uckun timuc...@gmail.com wrote: update cu set screenshot_file_name = tu.screenshot_file_name,    screenshot_content_type  = tu.screenshot_content_type,    screenshot_file_size = tu.screenshot_file_size,    screenshot_status  = tu.screenshot_status from  

Re: [GENERAL] Custom cache implemented in a postgresql C function

2010-10-21 Thread A.M.
On Oct 20, 2010, at 7:44 PM, Gabi Julien wrote: Hi, Here is my problem: I have a postgresql C function that looks like this: Datum filter(PG_FUNCTION_ARGS); It takes identifiers and queries a bunch of tables and ends up returning true or false. So far nothing difficult except that we

Re: [GENERAL] full vacuum cancelation

2010-10-21 Thread Vick Khera
On Thu, Oct 21, 2010 at 9:15 AM, Viktor Bojović viktor.bojo...@gmail.com wrote: my full vacuuming of one table runs still after four days. Is it safe to cancel it by pressing Ctrl+c? Is it really running (as in progressing with its work) or is it blocking waiting for a lock? Check the

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Brian Hirt
There are only two tables in the query. Tim, No, your query is written incorrectly. I don't understand why you come on to this list all hostile and confrontational. Regardless, people still try to help you and then you still ignore the advice of people that are giving you the solutions

[GENERAL] Advice needed on application/database authentication/authorization/auditing model

2010-10-21 Thread Tony Cebzanov
I have a web application with a Postgres backend. In my initial prototype, I decided not to have a Postgres database user created for each application user, opting instead to use my own users table. Authentication of application users is done via PAM, so no password is necessary in my users table

Re: [GENERAL] postgres services on amazon

2010-10-21 Thread Greg Smith
Aljoša Mohorović wrote: i know, i am using amazon services and have no issues with running postgres on ec2 but i'm more concern with the fact that it seems that nobody is planning to provide professional services comparable with the current mysql based services from amazon Just because none

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly.  I don't understand why you come on to this list all hostile and confrontational.  Regardless, people still try to help you and then you

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Rob Sargent
On 10/21/2010 10:27 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly. I don't understand why you come on to this list all hostile and confrontational.

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 10:37 AM, Rob Sargent robjsarg...@gmail.com wrote: On 10/21/2010 10:27 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly.  I don't understand

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Roberto Scattini
On Thu, Oct 21, 2010 at 1:37 PM, Rob Sargent robjsarg...@gmail.com wrote: On 10/21/2010 10:27 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly. I don't

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Rob Sargent
On 10/21/2010 10:45 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 10:37 AM, Rob Sargent robjsarg...@gmail.com wrote: On 10/21/2010 10:27 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Wed, 20 Oct 2010, Tom Lane wrote: Personally, I'd drop all the machinations with checking the pidfile or removing old socket files. Tom, I didn't write the script; whoever maintains the Slackware package for PostgreSQL did. Regardless, I'll make the changes you suggest. In particular,

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 11:18 AM, Rob Sargent robjsarg...@gmail.com wrote: On 10/21/2010 10:45 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 10:37 AM, Rob Sargent robjsarg...@gmail.com wrote: On 10/21/2010 10:27 AM, Scott Marlowe wrote: On Thu, Oct 21, 2010 at 9:33 AM, Brian Hirt

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 11:27 AM, Rich Shepard rshep...@appl-ecosys.com wrote:  Yet, when I try to access one of my databases I cannot: [rshep...@salmo ~]$ psql aesi psql: could not connect to server: No such file or directory        Is the server running locally and accepting        

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Scott Marlowe wrote: So, what do telnet localhost 5432 Scott, That port's clear: [rshep...@salmo ~]$ telnet localhost 5432 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. AND psql -h localhost -l Huh! [rshep...@salmo ~]$ psql -h localhost

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Lennin Caro
--- On Thu, 10/21/10, Reid Thompson reid.thomp...@ateb.com wrote: From: Reid Thompson reid.thomp...@ateb.com Subject: Re: [GENERAL] Cannot Start Postgres After System Boot To: Rich Shepard rshep...@appl-ecosys.com Cc: pgsql-general@postgresql.org Date: Thursday, October 21, 2010, 4:28 AM On

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Reid Thompson wrote: what does $ netstat -an|grep 5432 return? Reid, [rshep...@salmo ~]$ netstat -an|grep 5432 tcp0 0 127.0.0.1:5432 0.0.0.0:* LISTEN unix 3 [ ] STREAM CONNECTED 785432 what does $ ps -ef|grep

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Lennin Caro wrote: Try to delete the files like this .s.PGSQL.5432 .s.PGSQL.5432.lock 8.x-main.pid and restart postmaster Lennin, The sockets are not to be found. Rich -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Adrian Klaver
On 10/21/2010 10:41 AM, Rich Shepard wrote: On Thu, 21 Oct 2010, Reid Thompson wrote: what does $ netstat -an|grep 5432 return? Reid, [rshep...@salmo ~]$ netstat -an|grep 5432 tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN unix 3 [ ] STREAM CONNECTED 785432 what does $ ps -ef|grep post return?

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Adrian Klaver wrote: What does your postgresql.conf file show for ? : listen_addresses = Adrian, #listen_addresses = 'localhost' # what IP address(es) to listen on; This hasn't changed. Thanks, Rich -- Sent via pgsql-general mailing list

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Tom Lane
Rich Shepard rshep...@appl-ecosys.com writes: On Wed, 20 Oct 2010, Tom Lane wrote: In particular, I wonder whether the script's refusal to start if the pidfile already exists accounts for your report that it fails to auto-restart after a reboot. This clears up my uncertainty. The pidfile

Re: [GENERAL] Custom cache implemented in a postgresql C function

2010-10-21 Thread Gabi Julien
Thanks to all of you. This was very good feedback. I'll use the one cache per process suggestion of Tom Lane. This will be the easiest to implement. On Thursday 21 October 2010 11:14:40 A.M. wrote: On Oct 20, 2010, at 7:44 PM, Gabi Julien wrote: Hi, Here is my problem: I have a

Re: [GENERAL] Composite Index question

2010-10-21 Thread DM
Thank you for all your suggestions and answers. - Deepak On Wed, Oct 20, 2010 at 7:41 PM, mark dvlh...@gmail.com wrote: On 10/20/2010 05:43 PM, DM wrote: Composite Index question: I have composite index on 3 columns on a table, by mistake the composite index was created twice on the

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 11:36 AM, Lennin Caro lennin.c...@yahoo.com wrote: Try to delete the files like this .s.PGSQL.5432 .s.PGSQL.5432.lock 8.x-main.pid and restart postmaster WHOA, never delete those files unless you're sure you've killed off postgres first. Then and only then you can

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Reid Thompson
On Thu, 2010-10-21 at 10:35 -0700, Rich Shepard wrote: On Thu, 21 Oct 2010, Scott Marlowe wrote: So, what do telnet localhost 5432 Scott, That port's clear: [rshep...@salmo ~]$ telnet localhost 5432 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'.

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 11:35 AM, Rich Shepard rshep...@appl-ecosys.com wrote: On Thu, 21 Oct 2010, Scott Marlowe wrote: So, what do telnet localhost 5432 Scott,  That port's clear: [rshep...@salmo ~]$ telnet localhost 5432 Trying 127.0.0.1... Connected to localhost. Escape character

Re: [GENERAL] Question on Explain : Index Scan

2010-10-21 Thread DM
perfecto, thank you for the explanation. - Deepak On Thu, Oct 21, 2010 at 3:20 AM, Mathieu De Zutter math...@dezutter.orgwrote: On Thu, Oct 21, 2010 at 3:47 AM, DM dm.a...@gmail.com wrote: I was hoping the optimizer would do a join using index scan. Could some one please explain me why

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Adrian Klaver
On 10/21/2010 11:21 AM, Rich Shepard wrote: On Thu, 21 Oct 2010, Scott Marlowe wrote: WHOA, never delete those files unless you're sure you've killed off postgres first. Then and only then you can delete them and safely restart. If you ever manage to bring up two postmasters on the same store

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Tom Lane wrote: Actually, I was saying that the script should *not* concern itself with the pidfile at all. Tom, I understood what you wrote. Hmm, maybe the postmaster thinks it should be putting the socket file someplace other than /tmp. Have you got a nondefault

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Scott Marlowe wrote: WHOA, never delete those files unless you're sure you've killed off postgres first. Then and only then you can delete them and safely restart. If you ever manage to bring up two postmasters on the same store you've just destroyed your database.

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Reid Thompson wrote: what does $ netstat -an |grep 5432 return? something is running on tcp port 5432 Doesn't show that. [rshep...@salmo ~]$ netstat -an |grep 5432 tcp0 0 127.0.0.1:5432 0.0.0.0:* LISTEN Rich -- Sent via

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Scott Marlowe wrote: So a postgres IS running on your machine. I put it to you it's not running where you think it is. When I run 'ps ax | grep post' I found a few postgres processes. I tried '/etc/rc.d/rc.postgresql stop' but that had no effect. I killed the lowest

Re: [GENERAL] Question on Explain : Index Scan

2010-10-21 Thread DM
*Why is the difference in query plan, and the total runtime. Both tables have the same btree index* test=# explain analyze select * from test_seqindex1 where sid='AA023'; QUERY PLAN

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Reid Thompson
On Thu, 2010-10-21 at 11:38 -0700, Rich Shepard wrote: On Thu, 21 Oct 2010, Reid Thompson wrote: what does $ netstat -an |grep 5432 return? something is running on tcp port 5432 Doesn't show that. [rshep...@salmo ~]$ netstat -an |grep 5432 tcp0 0 127.0.0.1:5432

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Reid Thompson
On Thu, 2010-10-21 at 11:45 -0700, Rich Shepard wrote: On Thu, 21 Oct 2010, Scott Marlowe wrote: So a postgres IS running on your machine. I put it to you it's not running where you think it is. When I run 'ps ax | grep post' I found a few postgres processes. I tried

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Andrej
On 22 October 2010 07:45, Rich Shepard rshep...@appl-ecosys.com wrote:  When I run 'ps ax | grep post' I found a few postgres processes. I tried '/etc/rc.d/rc.postgresql stop' but that had no effect. I killed the lowest numbered process and that removed them all. However, I still cannot start a

Re: [GENERAL] Cannot Start Postgres After System Boot [SOLVED]

2010-10-21 Thread Rich Shepard
On Thu, 21 Oct 2010, Adrian Klaver wrote: The missing piece of information seems to be the system board failure. My guess is that caused corruption. See if you can connect by doing: psql -h localhost -d aesi Adrian, [rshep...@salmo ~]$ psql -h localhost -d aesi psql: could not connect to

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 12:38 PM, Rich Shepard rshep...@appl-ecosys.com wrote: On Thu, 21 Oct 2010, Reid Thompson wrote: what does $ netstat -an |grep 5432 return? something is running on tcp port 5432  Doesn't show that. [rshep...@salmo ~]$ netstat -an |grep 5432 tcp        0      0

Re: [GENERAL] Cannot Start Postgres After System Boot

2010-10-21 Thread Tom Lane
Rich Shepard rshep...@appl-ecosys.com writes: Since I cannot start the postmaster I cannot run pg_dumpall. As far as I can tell you *are* starting the postmaster, and it is responding when you query it via TCP (eg, with psql -h localhost). What is not working is connections via the Unix

Re: [GENERAL] Advice needed on application/database authentication/authorization/auditing model

2010-10-21 Thread Dmitriy Igrishin
Hey Tony, 2010/10/21 Tony Cebzanov tony...@andrew.cmu.edu I have a web application with a Postgres backend. In my initial prototype, I decided not to have a Postgres database user created for each application user, opting instead to use my own users table. IMO, you are trying to reinvent

[GENERAL] COPY question

2010-10-21 Thread Szymon Guz
Hi, I still get the same error while using COPY FROM 'file'. I have to pass the full directory for this to work, example: COPY first (a,b,c) FROM '1st_file.csv' with csv header delimiter ','; ERROR: could not open file 1st_file.csv for reading: No such file or directory The same when I use:

Re: [GENERAL] COPY question

2010-10-21 Thread Szymon Guz
On 21 October 2010 23:28, Raymond O'Donnell r...@iol.ie wrote: On 21/10/2010 22:16, Szymon Guz wrote: Hi, I still get the same error while using COPY FROM 'file'. I have to pass the full directory for this to work, example: COPY first (a,b,c) FROM '1st_file.csv' with csv header delimiter

Re: [GENERAL] COPY question

2010-10-21 Thread Raymond O'Donnell
On 21/10/2010 22:16, Szymon Guz wrote: Hi, I still get the same error while using COPY FROM 'file'. I have to pass the full directory for this to work, example: COPY first (a,b,c) FROM '1st_file.csv' with csv header delimiter ','; ERROR: could not open file 1st_file.csv for reading: No such

Re: [GENERAL] Gripe: bytea_output default = data corruption

2010-10-21 Thread Bruce Momjian
Rajesh Kumar Mallah wrote: Dear Griper!, fortunately someone showed a easy 'fix' ALTER DATABASE foo SET bytea_output='escape' ; Yes, we mentioned that setting in the release notes too: E.2.3.5. Data Types * Allow bytea values to be

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Tim Uckun
On Fri, Oct 22, 2010 at 4:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly.  I don't understand why you come on to this list all hostile and confrontational.  Regardless, people still try to help you and then you

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Tim Uckun
True. His only real snark was in reponse to the let me google that for you link. OTOH, he's arguing with Tom Lane about whether his SQL is well formed. There's arguing on the internet is stupid, then there's arguing with Tom Lane about SQL is stupid. I wasn't arguing with Tom Lane about

Re: [GENERAL] Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Scott Marlowe
On Thu, Oct 21, 2010 at 4:31 PM, Tim Uckun timuc...@gmail.com wrote: On Fri, Oct 22, 2010 at 4:33 AM, Brian Hirt bh...@me.com wrote: There are only two tables in the query. Tim, No, your query is written incorrectly.  I don't understand why you come on to this list all hostile and

Re: [GENERAL] Gripe: bytea_output default = data corruption

2010-10-21 Thread ljb
br...@momjian.us wrote: ... Yes, we mentioned that setting in the release notes too: ... While the Incompatibilities section mentions only the first paragraph, this remention lower down has even more details. Not sure what else you wanted us to do. Here's how I would have written that first

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread David Kerr
On Wed, Oct 20, 2010 at 09:35:11PM -0700, Darren Duncan wrote: - Josh Kupershmidt wrote: - On Wed, Oct 20, 2010 at 6:22 PM, David Kerr d...@mr-paradox.net wrote: - I know I've seen posts on how to do this, but i can't seem to find them. - - I've got a data set - - A, B - A, C - A, D - [...] - -

[GENERAL] compile error in libpq program

2010-10-21 Thread zab08
I use this command to compile the libpq.c. cc -I /opt/PostgreSQL/8.4/include -o libpq libpq.c -L /opt/PostgreSQL/8.4/lib -lpq but I get these error: /usr/bin/ld: warning: libssl.so.4, needed by /opt/PostgreSQL/8.4/lib/libpq.so, not found (try using -rpath or -rpath-link) /usr/bin/ld: warning:

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread Daniel Verite
David Kerr wrote: Well, an upgrade's not on tap for a few months. Until then i'll need to figure out somethnig else. This may help: http://www.depesz.com/index.php/2007/08/17/rownum-anyone-cumulative-sum-in-on e-query/ or http://preview.tinyurl.com/mc4q6p Best regards, -- Daniel

Re: [GENERAL] compile error in libpq program

2010-10-21 Thread John R Pierce
On 10/21/10 5:24 PM, zab08 wrote: I use this command to compile the libpq.c. *cc -I /opt/PostgreSQL/8.4/include -o libpq libpq.c -L /opt/PostgreSQL/8.4/lib -lpq* * * but I get these error: /usr/bin/ld: warning: libssl.so.4, needed by /opt/PostgreSQL/8.4/lib/libpq.so, not found (try using

Re: [GENERAL] COPY question

2010-10-21 Thread Craig Ringer
On 10/22/2010 05:16 AM, Szymon Guz wrote: Hi, I still get the same error while using COPY FROM 'file'. I have to pass the full directory for this to work, example: Sounds like you want to be using psql's \copy, not the server side COPY. \copy is aware of your current working directory and