Re: [GENERAL] Postgres 9.3 tuning advice

2014-08-13 Thread Albe Laurenz
dushy wrote: Iam running a postgresql 9.0.13 master/slave instance in a write heavy workload. The hardware is a Dell 720, E5530 - 8 core, 128GB RAM. The database (around 250g with indexes/bloat etc) is sitting on flashcache device with 2 fusion- io PCIe MLC SSDs as frontend and a MD3200

Re: [GENERAL] Inserting large binary data into lo type table

2014-08-13 Thread Albe Laurenz
Jose Moreira wrote: I guess this is easy a question for the gurus, but afraid I cannot get te answer! I have this table: aif_test=# \d sbox; Table public.sbox Column | Type | Modifiers ++--- id | character

Re: [GENERAL] PostgreSQL as a triple store

2014-08-13 Thread Seref Arikan
Hi Jimmy, I think you're going to need to perform experiments and decide if the flexibility you get is worth the performance you're going to lose. As you can see from John R Pierce's response it is only matter of time before someone (correctly) warns you about the performance issues with EAV

Re: [GENERAL] Database block lifecycle

2014-08-13 Thread pinker
Jeff Janes wrote On Tuesday, August 12, 2014, pinker lt; pinker@ gt; wrote: Do you ever plan on restarting this server? Doing maintenance? Applying security patches? Sure, I assumed when db is up and running, of course after first read from disk when whole data should be in RAM.

Re: [GENERAL] PostgreSQL as a triple store

2014-08-13 Thread Chris Travers
On Wed, Aug 13, 2014 at 12:43 AM, Seref Arikan serefari...@gmail.com wrote: Hi Jimmy, I think you're going to need to perform experiments and decide if the flexibility you get is worth the performance you're going to lose. As you can see from John R Pierce's response it is only matter of time

[GENERAL] Can I see the detailed log of query fired by particular Postgres client on Postgres server?

2014-08-13 Thread M Tarkeshwar Rao
Hi all, Can I see the detailed log of query fired by particular Postgres client on Postgres server? This client might be any java application or any console Postgres client. I want this for our debugging purpose. Regards Tarkeshwar

Re: [GENERAL] Can I see the detailed log of query fired by particular Postgres client on Postgres server?

2014-08-13 Thread Soni M
On each session created by the client, run set log_statement to 'all' before firing your query On Wed, Aug 13, 2014 at 4:21 PM, M Tarkeshwar Rao m.tarkeshwar@ericsson.com wrote: Hi all, Can I see the detailed log of query fired by particular Postgres client on Postgres server?

Re: [GENERAL] Can I see the detailed log of query fired by particular Postgres client on Postgres server?

2014-08-13 Thread M Tarkeshwar Rao
Thanks for reply. We tried it but it is creating blank log file on pg_log. From: Soni M [mailto:diptat...@gmail.com] Sent: 13 August 2014 15:02 To: M Tarkeshwar Rao Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Can I see the detailed log of query fired by particular Postgres client on

Re: [GENERAL] Can I see the detailed log of query fired by particular Postgres client on Postgres server?

2014-08-13 Thread Soni M
check you postgresql.conf, where you're heading your log, log_destination, etc. http://www.postgresql.org/docs/9.1/static/runtime-config-logging.html On Wed, Aug 13, 2014 at 4:37 PM, M Tarkeshwar Rao m.tarkeshwar@ericsson.com wrote: Thanks for reply. We tried it but it is creating

Re: [GENERAL] Postgres 9.3 tuning advice

2014-08-13 Thread Marti Raudsepp
On Wed, Aug 13, 2014 at 9:44 AM, Albe Laurenz laurenz.a...@wien.gv.at wrote: Set wal_buffers to 16MB so that a whole WAL segment will fit. No need, wal_buffers is automatically tuned now. If your shared_buffers is 512MB or larger, wal_buffers will be 16MB. Regards, Marti -- Sent via

Re: [GENERAL] PostgreSQL as a triple store

2014-08-13 Thread Jimmy Thrasibule
I think you're going to need to perform experiments and decide if the flexibility you get is worth the performance you're going to lose. As you can see from John R Pierce's response it is only matter of time before someone (correctly) warns you about the performance issues with EAV derivatives,

Re: [GENERAL] Database block lifecycle

2014-08-13 Thread Jeff Janes
On Wed, Aug 13, 2014 at 1:07 AM, pinker pin...@onet.eu wrote: btw. 512MB if we assume up to 600 connection is a reasonable value? Reasonable value for what? For normal server load. 512MB is being questioned as a reasonable value for what? shared_buffers? work_mem?

Re: [GENERAL] Database block lifecycle

2014-08-13 Thread Robin
On 13/08/2014 17:23, Jeff Janes wrote: On Wed, Aug 13, 2014 at 1:07 AM, pinker pin...@onet.eu mailto:pin...@onet.eu wrote: btw. 512MB if we assume up to 600 connection is a reasonable value? Reasonable value for what? For normal server load. 512MB is

[GENERAL] Trigger function cannot reference field name with capital letter

2014-08-13 Thread Patrick Dung
Hello PGSQL users, I have a field called postTimestamp. The trigger function could not reference it. When I change my field to post_timestamp. I can reference it from the tigger function. Version is 9.3.5. Any comment? 2014-08-14 00:23:32.717 HKT ERROR:  post new has no field posttimestamp

Re: [GENERAL] Trigger function cannot reference field name with capital letter

2014-08-13 Thread Adrian Klaver
On 08/13/2014 08:52 PM, Patrick Dung wrote: Hello PGSQL users, I have a field called postTimestamp. The trigger function could not reference it. When I change my field to post_timestamp. I can reference it from the tigger function. Version is 9.3.5. Any comment? 2014-08-14 00:23:32.717 HKT

Re: [GENERAL] Trigger function cannot reference field name with capital letter

2014-08-13 Thread John R Pierce
On 8/13/2014 8:52 PM, Patrick Dung wrote: I have a field called postTimestamp. The trigger function could not reference it. When I change my field to post_timestamp. I can reference it from the tigger function. Version is 9.3.5. Any comment? 2014-08-14 00:23:32.717 HKT ERROR: post new has

Re: [GENERAL] Trigger function cannot reference field name with capital letter

2014-08-13 Thread John R Pierce
On 8/13/2014 9:13 PM, John R Pierce wrote: SELECT * from tbl1 where new.postTimestamp' timestamp '2014-01-01 00:00:00' oops. SELECT * from tbl1 where new.postTimestamp timestamp '2014-01-01 00:00:00' I meant. I should proof what I write, hah! -- john r pierce

[GENERAL] Pass where clause to a function

2014-08-13 Thread Andrew Bartley
Hi all, Is it possible to create a view or foreign table that will do something like this select * from table_x where x_id = 10; passing the where x_id = 10 to a function sorta like this select * from api_function('x = 10') or select * from api_function(10) passing the result set back to

Re: [GENERAL] Pass where clause to a function

2014-08-13 Thread John R Pierce
On 8/13/2014 10:08 PM, Andrew Bartley wrote: Is it possible to create a view or foreign table that will do something like this select * from table_x where x_id = 10; passing the where x_id = 10 to a function sorta like this select * from api_function('x = 10') or select * from