Re: [GENERAL] raise notice question

2017-01-14 Thread Tom Lane
ProPAAS DBA writes: > Is it possible to execute a raise notice without the "Notice" keyword > being part of the output, or is there another construct that allows > writing to output as simple informational text (without any sort of > NOTICE, WARNING, etc being part of the output? This is a mat

Re: [GENERAL] COPY value TO STDOUT

2017-01-14 Thread Tom Lane
Denisa Cirstescu writes: > I want to COPY a value to STDOUT from PL/pgSQL language. You can't. Maybe RAISE NOTICE would serve the purpose? > I saw that the STDOUT is not accessible from PL/pgSQL, but it is from SQL. > This is why I am trying to create an auxiliary function declared as language

Re: [GENERAL] raise notice question

2017-01-14 Thread Pavel Stehule
Hi 2017-01-14 17:29 GMT+01:00 ProPAAS DBA : > Is it possible to execute a raise notice without the "Notice" keyword > being part of the output, or is there another construct that allows writing > to output as simple informational text (without any sort of NOTICE, > WARNING, etc being part of the

Re: [GENERAL] COPY value TO STDOUT

2017-01-14 Thread Pavel Stehule
Hi 2017-01-13 16:45 GMT+01:00 Denisa Cirstescu : > I am not sure if this is the correct mailing list or if this is how you > submit a question, but I am going to give it a try. > > > > I want to COPY a value to STDOUT from PL/pgSQL language. > > > > I saw that the STDOUT is not accessible from P

Re: [GENERAL] Timestamp index not being hit

2017-01-14 Thread Tom Lane
Andreas Terrius writes: > --Query 2, Does not hit index > SELECT * FROM idxtbl > where ( current_timestamp is null or btime < current_timestamp) > AND ( current_timestamp - INTERVAL '7 DAYS' is null or btime > > current_timestamp - INTERVAL '7 DAYS') > --Query 4, Hit Index > SELECT * FROM idxtbl

[GENERAL] raise notice question

2017-01-14 Thread ProPAAS DBA
Is it possible to execute a raise notice without the "Notice" keyword being part of the output, or is there another construct that allows writing to output as simple informational text (without any sort of NOTICE, WARNING, etc being part of the output? Thanks in advance -- Sent via pgsql

[GENERAL] Timestamp index not being hit

2017-01-14 Thread Andreas Terrius
Hello Ive been running into an issue with postgresql not hitting index on select queries. Below is the sql query I used to test my issue. CREATE TABLE idxtbl ( id BIGINT, aint BIGINT, btime TIMESTAMPTZ, ctext TEXT, dbool BOOLEAN, PRIMARY KEY(id) ); --Inserted 10 mil random data /* TEST TIMESTAMP

[GENERAL] COPY value TO STDOUT

2017-01-14 Thread Denisa Cirstescu
I am not sure if this is the correct mailing list or if this is how you submit a question, but I am going to give it a try. I want to COPY a value to STDOUT from PL/pgSQL language. I saw that the STDOUT is not accessible from PL/pgSQL, but it is from SQL. This is why I am trying to create an aux

[GENERAL] Re: Are new connection/security features in order, given connection pooling?

2017-01-14 Thread Karl Czajkowski
On Jan 14, Tomas Vondra modulated: ... > Sure, a lot of systems generate queries on the fly. Also, if the > main problem is poor plan choice due to RLS, I'm not sure how > prepared statements could help with that. > Sorry for being unclear, I was trying to respond to too many sub-topics at once.