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 |

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 deriva

Re: [GENERAL] Database block lifecycle

2014-08-13 Thread pinker
Jeff Janes wrote > On Tuesday, August 12, 2014, pinker < > pinker@ > > 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 RA

Re: [GENERAL] PostgreSQL as a triple store

2014-08-13 Thread Chris Travers
On Wed, Aug 13, 2014 at 12:43 AM, Seref Arikan 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 > before someone

[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 serve

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 P

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 bl

Re: [GENERAL] Postgres 9.3 tuning advice

2014-08-13 Thread Marti Raudsepp
On Wed, Aug 13, 2014 at 9:44 AM, Albe Laurenz 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 pgsql-general mailing list (pgs

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 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? maintenan

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 > 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 q

[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 "posttimestam

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 >E

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" ha

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 api_fun

Re: [GENERAL] Pass where clause to a function

2014-08-13 Thread Andrew Bartley
Hi John, Thanks for the response I need this because it is a customer requirement. The underlying tables the api will query are dynamically created, they are period/content partitioned and distributed across multiple servers and database types... not just postgres. The api/function will determi

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

2014-08-13 Thread Patrick Dung
Thanks all for the help. BTW, letter casing is just a preference. Some people liked to use all small caps, some liked to use all big caps. I sometimes found that mixed case is more meaningful for the filed (eg. serialnumber vs serialNumber) What is your preference or suggestion? On Thursday,

Re: [GENERAL] Pass where clause to a function

2014-08-13 Thread John R Pierce
On 8/13/2014 10:59 PM, Andrew Bartley wrote: I need this because it is a customer requirement. The underlying tables the api will query are dynamically created, they are period/content partitioned and distributed across multiple servers and database types... not just postgres. The api/functio

Re: [GENERAL] PostgreSQL on AIX platform

2014-08-13 Thread Patrick Dung
Hi Payal, I haven't tried Postgresql on AIX. This web site provides binary and if you like to build yourself, it provided build instruction too. http://www.perzl.org/aix/ http://www.perzl.org/aix/index.php?n=Main.Instructions Thanks and regards, Patrick On Saturday, August 9, 2014 6:28 AM, Pa

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

2014-08-13 Thread Pavel Stehule
Hi 2014-08-14 8:10 GMT+02:00 Patrick Dung : > Thanks all for the help. > > BTW, letter casing is just a preference. > Some people liked to use all small caps, some liked to use all big caps. > I sometimes found that mixed case is more meaningful for the filed (eg. > serialnumber vs serialNumber)

Re: [GENERAL] Pass where clause to a function

2014-08-13 Thread Alban Hertroys
On 14 Aug 2014, at 7:59, Andrew Bartley wrote: > I need this because it is a customer requirement. The underlying tables the > api will query are dynamically created, they are period/content partitioned > and distributed across multiple servers and database types... not just > postgres. The