[GENERAL] Was: BUG #13883: Very Important Facility

2016-01-25 Thread Vitaly Burovoy
On 1/25/16, d...@nym.hush.com  wrote:
> Vitaly
>
> Thanks for the response. With 35 million users I am glad Joomla now
> supports postgreSQL. There are 10s of thousands of extensions but
> support there is lacking.
Unfortunately experience of Python with refactoring internal API from
version 2 to 3 shows that authors of extensions (especially big ones)
need years to change their code. And those Python versions are almost
the same language (there is a tool "2to3" out of the box)!
Fortunately if users regularly remind the authors that the new
behavior (or support of the new version) is important for them, things
change.

> Is it a lack of knowledge?
Sometimes yes, sometimes no.
It is the simplest way to support something single that you knows
well. But when you have to support different similar things you have
to have an extra abstract layer, complex testing tools (for each
different thing and often for cross-thing) etc. Also you can't use
advantages of the one database because it lacks in the other one (and
vice versa).
While Joomla doesn't have Postgres support, there is no reason for the
authors of extensions to deal with that DBMS.

> I will pass your advice onto the Akeeba team and I hope it spurs them on to 
> do something.
> Maybe they will contact you if they need more help.
Welcome!

> Joomla has a list of extensions that you can download and install but
> there is no icon indicating postgreSQL support.
There is no icon indicating MySQL and MSSQL support too.
But anyone can find necessary information on the "Installing" page
("Requirements" block):
https://docs.joomla.org/J3.x:Installing_Joomla

> You only find out
> about the support when the error messages come. I have notified the
> Joomla team with this suggestion. That is as much as I can do to speed
> up PostgreSQL uptake in Joomla for now.
>
> Thanks for providing postgreSQL to us.
You are welcome.

>
> Best wishes,
> Dominic

-- 
Best regards,
Vitaly Burovoy


-- 
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] request for comment re "contributor-covenant.org"

2016-01-25 Thread Josh Berkus
Mr. Harkness,

First, the discussion you reference is now materially over.

Second, you are not an administrator of this, or any other PostgreSQL
mailing list of which I am aware.  As such, you are in no position to
dictate what is, or is not, acceptable on this list and will get someone
"banned"; only our Infra Team can do that.  Please do not presume to do
so for them.

-- 
Josh Berkus
Red Hat OSAS
(opinions are my own)


-- 
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Igal @ Lucee.org

On 1/25/2016 10:51 PM, Thomas Kellerer wrote:

Very helpful, thanks.

Great, thank you for the feedback.

Is there any tutorial on how to compile extensions for Windows?

There are many interesting extensions where no Windows binaries are available, 
so it would be really helpful if I could compile them myself.
I'm actually trying to figure those things out, and once I do 
(hopefully) I plan to post similar tutorials.


My top two extensions of interest are plv8 and tds_fdw.


Igal




--
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] How to transfer from place to plase without backup/restore

2016-01-25 Thread anvesh
It can done through cloud based services like using drop box or google drive. 
Happy Rose Day

  
They have worked like a charm for me.. Happy Chocolate Day
   I think there are various number of other 3rd
party applications that have been  Happy Valentines Day Quotes
   developed in the later
months  Hug Day 2016

  



--
View this message in context: 
http://postgresql.nabble.com/How-to-transfer-from-place-to-plase-without-backup-restore-tp1890462p5884194.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
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] request for comment re "contributor-covenant.org"

2016-01-25 Thread Zenaan Harkness
Hi Josh,

I simply wrote in first person with the intention to catalyse thought
about what could and or should and or should not be in such a
"covenant". In no way was the email any statement of authority and I
had hoped to make that clear, evidently not.

Evidently it was not clear enough despite my disclaimer at the top.

My sincere apologies for the confusion - such confusion was seriously
not wanted by me and I apologise unreservedly.

On the topic, I feel it will take a few years yet for "the libre
software community" to come to anything approaching a consensus
regarding "community covenant"; just my opinion of course.

Regards,
Zenaan


On 1/26/16, Josh Berkus  wrote:
> Mr. Harkness,
>
> First, the discussion you reference is now materially over.
>
> Second, you are not an administrator of this, or any other PostgreSQL
> mailing list of which I am aware.  As such, you are in no position to
> dictate what is, or is not, acceptable on this list and will get someone
> "banned"; only our Infra Team can do that.  Please do not presume to do
> so for them.
>
> --
> Josh Berkus
> Red Hat OSAS
> (opinions are my own)


-- 
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Thomas Kellerer
Igal @ Lucee.org schrieb am 25.01.2016 um 19:46:
> I have posted a video tutorial on How to Compile PostgreSQL 9.5 for Windows 
> 64bit
> https://www.youtube.com/watch?v=-BJmuZT5IPE
> 
> It was quite difficult for me to figure it out, so hopefully it will make 
> life easier for
> the next guy (or gal).

Very helpful, thanks. 

Is there any tutorial on how to compile extensions for Windows? 

There are many interesting extensions where no Windows binaries are available, 
so it would be really helpful if I could compile them myself.

Regards
Thomas
 



-- 
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] ERROR: check constraint - PostgreSQL 9.2

2016-01-25 Thread Vitaly Burovoy
On 1/24/16, Christophe Pettus  wrote:
>
> On Jan 24, 2016, at 9:01 PM, Charles Clavadetscher
>  wrote:
>
>> What is the point of having a check constraint that is not checked?
>
> Well, it *is* checked going into the future; it's just not checked at the
> time the constraint is added.  Ultimately, you do want to fix the data, but
> this makes it a two-step process, and reduces the time the table is locked
> against access.

NOT VALID constraint checks new and updated rows, and gives an extra
time to fix current data and be sure there will be no new rows that
violates the check constraint during and after the fixing process.

N.B.: Prior 9.4 it does *NOT* reduce the time the table is locked
because VALIDATE CONSTRAINT requires ACCESS EXCLUSIVE[1] and uses
seqscan for check table's rows.

P.S. Lucas, If you have not received answers, you can find all of them
as a thread by the link:
http://www.postgresql.org/message-id/flat/CAE_gQfXTns1FR5Fx9wxpo1oZYwat639ua-gAqWZyNg201HCU=q...@mail.gmail.com

P.P.S.:  Christophe, Charles! Please, use "Relpy to all" to be sure
the sender gets your answers even if he haven't subscribed to the
mailing list.

[1]http://www.postgresql.org/docs/9.2/static/sql-altertable.html
-- 
Best regards,
Vitaly Burovoy


-- 
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] ERROR: check constraint - PostgreSQL 9.2

2016-01-25 Thread Charles Clavadetscher
Hello Vitaly

> -Original Message-
> From: Vitaly Burovoy [mailto:vitaly.buro...@gmail.com]
> Sent: Montag, 25. Januar 2016 14:25
> To: Christophe Pettus ; clavadetsc...@swisspug.org
> Cc: Postgres General 
> Subject: Re: [GENERAL] ERROR: check constraint - PostgreSQL 9.2
> 
> On 1/24/16, Christophe Pettus  wrote:
> >
> > On Jan 24, 2016, at 9:01 PM, Charles Clavadetscher
> >  wrote:
> >
> >> What is the point of having a check constraint that is not checked?
> >
> > Well, it *is* checked going into the future; it's just not checked at the
> > time the constraint is added.  Ultimately, you do want to fix the data, but
> > this makes it a two-step process, and reduces the time the table is locked
> > against access.
> 
> NOT VALID constraint checks new and updated rows, and gives an extra
> time to fix current data and be sure there will be no new rows that
> violates the check constraint during and after the fixing process.
> 
> N.B.: Prior 9.4 it does *NOT* reduce the time the table is locked
> because VALIDATE CONSTRAINT requires ACCESS EXCLUSIVE[1] and uses
> seqscan for check table's rows.
> 
> P.S. Lucas, If you have not received answers, you can find all of them
> as a thread by the link:
> http://www.postgresql.org/message-id/flat/CAE_gQfXTns1FR5Fx9wxpo1oZYwat639ua-gAqWZyNg201HCU=q...@mail.gmail.com
> 
> P.P.S.:  Christophe, Charles! Please, use "Relpy to all" to be sure
> the sender gets your answers even if he haven't subscribed to the
> mailing list.

Oops. Honestly I did not think of that. I will keep that in mind in the future.
Thank you for the hint.

Charles

> 
> [1]http://www.postgresql.org/docs/9.2/static/sql-altertable.html
> --
> Best regards,
> Vitaly Burovoy



-- 
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Joshua D. Drake

On 01/25/2016 10:49 AM, Joshua Berkus wrote:



- Original Message -

Hi Everybody,

I have posted a video tutorial on How to Compile PostgreSQL 9.5 for
Windows 64bit
https://www.youtube.com/watch?v=-BJmuZT5IPE

It was quite difficult for me to figure it out, so hopefully it will
make life easier for
the next guy (or gal).


Wow, thanks for doing that!



Yes, no doubt. Can we get this linked somewhere so we don't lose it?

JD

--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Joshua Berkus


- Original Message -
> Hi Everybody,
> 
> I have posted a video tutorial on How to Compile PostgreSQL 9.5 for
> Windows 64bit
> https://www.youtube.com/watch?v=-BJmuZT5IPE
> 
> It was quite difficult for me to figure it out, so hopefully it will
> make life easier for
> the next guy (or gal).

Wow, thanks for doing that!

-- 
Josh Berkus
Red Hat OSAS
(opinions are my own)


-- 
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] CoC [Final v2]

2016-01-25 Thread Joshua D. Drake

Hello,

This thread is deprecated. The CoC Final Draft has been submitted to 
-core for final modification, acceptance or decline.


Sincerely,

Joshua D. Drake

--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
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] A motion

2016-01-25 Thread Joshua D. Drake

Hello,

This thread is deprecated. The CoC Final Draft has been submitted to 
-core for final modification, acceptance or decline.


Sincerely,

Joshua D. Drake

--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
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] CoC [Final v2]

2016-01-25 Thread Brian Dunavant
>> Participation does not need to be limited to copy-editing.  Of all the
>> ways to develop a community CoC, we're engaged in just about the worst
>> possible one right now.
>
> so what would be a better way of developing this ?

Of interesting note, the Ruby community is currently considering
switching to a CoC inspired directly from this draft of a Postgres
CoC.   The extremely long conversation can be viewed at:

https://redmine.ruby-lang.org/issues/12004


-- 
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] long transfer time for binary data

2016-01-25 Thread Daniel Verite
Johannes wrote:

> \lo_export 12345 /dev/null is completed in 0.86 seconds.

If it's an 11MB file through a 100Mbits/s network, that's
pretty much the best that can be expected.

I would think the above is the baseline against which
the other methods should be compared.

> I sa my images as large object, which afaik is in practise not
> readable with a binary cursor (we should use the lo_* functions). And of
> course I already use the LargeObjectManager of the postgresql jdbc library.

Sounds good.

> You said, the server has to convert the bytes to hex string before
> sending it over the wire.

Only in certain contexts. SELECT lo_get(oid) is a query that returns
bytea, so if the clients requests results in text format, they will
be transferred as text, and it's the responsibility of the client
to convert them back to bytes (or not, who knows, maybe the
client wants hexadecimal).

But lo_get is an exception, and besides a late addition (9.4 I believe).
Generally, client-side access to large objects functions doesn't
use a client-side SQL query, it's done through the 
"Function Call sub-protocol" described here:
http://www.postgresql.org/docs/current/static/protocol-flow.html#AEN108750
and the result comes back as binary.

Presumably the JDBC LargeObjectManager uses that method.

Best regards,
-- 
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite


-- 
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] A motion

2016-01-25 Thread John McKown
On Mon, Jan 25, 2016 at 1:08 PM, Melvin Davidson 
wrote:

> Although it has been previously disregarded, I would like to second the
> motion that all further discussion regarding the CoC go to it's own list.
>
> Consider this.
> 1. The Coc will eventually apply to ALL PostgreSQL mail lists.
> 2. There will be a need to have additions and revisions to the Coc.
> 3. As this list is for General (and mostly technical discussions) further
> discussions/emails concerning the CoC only distracts from the purpose of
> this email list.
>
>
​Complete agreement. I've kept my hands silent through force of will. Those
who are interested can create a CoC to their heart's content. I will abide
by it or not as I decide. But I try to be acceptably pleasant in all
discussions, even when I disagree with someone.

This thread has been a completely useless; requiring extreme use of my
delete key.​


-- 
Werner Heisenberg is driving down the autobahn. A police officer pulls
him over. The officer says, "Excuse me, sir, do you know how fast you
were going?"
"No," replies Dr. Heisenberg, "but I know where I am."

Computer Science is the only discipline in which we view adding a new wing
to a building as being maintenance -- Jim Horning

Schrodinger's backup: The condition of any backup is unknown until a
restore is attempted.

He's about as useful as a wax frying pan.

Maranatha! <><
John McKown


Re: [GENERAL] CoC [Final v2]

2016-01-25 Thread John R Pierce

On 1/25/2016 8:39 AM, Brian Dunavant wrote:

Of interesting note, the Ruby community is currently considering
switching to a CoC inspired directly from this draft of a Postgres
CoC.   The extremely long conversation can be viewed at:

https://redmine.ruby-lang.org/issues/12004



again, people there are bringing up the 'feel safe' thing.Noone can 
help how people feel, feelings are highly subjective.   Some people feel 
threatened by a fur coat on a random passerby, or by a woman not covered 
head to toe in a burka.   I know people who don't feel safe unless they 
are carrying a loaded gun, yet random strangers carrying guns make ME 
feel very unsafe.


I'm just a postgresql user who occasionally contributes to this and 
other mail lists, so my 'vote' on this has very little weight, but I 
want to again state, in my personal opinion, IF PGDG adopts a CoC, it 
should be as simple, terse, and generic as possible.   As soon as you 
start enumerating possible social injustices you are on a very slippery 
slope.   Next thing you know, you'll need courts, lawyers, hearings, 
legislature, and are reinventing 'government', and you end up with more 
overhead than actual code contributors.


meanderings, only indirectly related to this...

On the centos email list, some people were bashing gnome3 (probably for 
good reasons).  I looked up the gnome project (mostly, read the 
wikipedia entries relating to it, also a few recent blogs by core 
developers).  Gnome started as a 2-man volunteer project, grew, had a 
mission to develop a complete desktop environment unencumbered by close 
source licensing issues that KDE's QT had(past tense), and by Gnome 2 
had largely succeeded in these goals.Now Gnome has a 'Project' (with 
hierarchical management) and a 'Foundation' (with hierarchical 
management) , and the last 'Foundation' chair was more interested in 
organizing Outreachy, a 'outreach group for women in free software' 
promotional group (a fine thing but completely unrelated to gnome), and 
the gnome core developers are quitting right and left for lack of a firm 
direction or mission, and lack of resources.   Everyone, including many 
of those developers, are unhappy with gnome 3, but have no idea how to 
fix it.


Over my long and checkered career in computer software, I've worked for 
several startups where the founder was a brilliant technical person with 
no business sense...  when the business got too big for them, they 
allowed money people to install 'business people' as CEOs and stuff, 
these business people had no clue how software development operated and 
tried to treat it like whatever industry they'd come from (one CEO was a 
former PepsiCo VP!   He top-loaded the place with MBA yes-men and 
Marketing).   The founder withdrew into his own bubble off working on 
pet projects, and the company floundered around for a few more years, 
then crashed and burned.



--
john r pierce, recycling bits in santa cruz



--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] help:error while running postgres after installing postgresql server from source code

2016-01-25 Thread Shubham Barai
I was trying to install postgresql from source code on ubuntu.I followed
all the instructions and installed all the packages.I was also able to
create database cluster but when I executed this command 'postgres -D
/usr/local/pgsql/data' I got this

 $ postgres -D /usr/local/pgsql/data
> The program 'postgres' is currently not installed. You can install it by
> typing:
> sudo apt-get install postgres-xc


Re: [GENERAL] TABLESAMPLE usage

2016-01-25 Thread Tom Smith
Yeah. I am looking for fastest possible method that Postgresql would
use its internal data structure knowledge to walk through the timestamp
index
and resturns every "nth" row

On Mon, Jan 25, 2016 at 5:56 AM, Simon Riggs  wrote:

> On 25 January 2016 at 09:44, Matija Lesar  wrote:
>
>
>> you can accomplish this with row_number()
>> 
>> :
>>
>> WITH data_cte as (
>> SELECT
>> id,
>> clock_timestamp() as ctimestamp
>> FROM generate_series(1,1000) as id
>> )
>> SELECT
>> *
>> FROM
>> (SELECT
>> id,
>> ctimestamp,
>> row_number() OVER (ORDER BY ctimestamp) as rownum
>> FROM data_cte
>> ) as data_withrownumbers
>> WHERE
>> rownum%100=1;
>>
>
> You can, but its not very fast.
>
> --
> Simon Riggshttp://www.2ndQuadrant.com/
> 
> PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
>


Re: [GENERAL] help:error while running postgres after installing postgresql server from source code

2016-01-25 Thread Shulgin, Oleksandr
On Sat, Jan 23, 2016 at 6:42 PM, Shubham Barai 
wrote:
>
> I was trying to install postgresql from source code on ubuntu.I followed
all the instructions and installed all the packages.I was also able to
create database cluster but when I executed this command 'postgres -D
/usr/local/pgsql/data' I got this
>
>  $ postgres -D /usr/local/pgsql/data
> > The program 'postgres' is currently not installed. You can install it by
> > typing:
> > sudo apt-get install postgres-xc

That really depends on where you did install the binary files.  Did you
specify a --prefix option when running configure script?  If so, you might
need a command like the following:

$ /usr/local/pgsql/bin/postgres -D /usr/local/pgsql/data

Actually, assuming you've created the database by using the newly installed
initdb command, you just need to replace "initdb" with "postgres" in that
command.

--
Alex


[GENERAL] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Igal @ Lucee.org

Hi Everybody,

I have posted a video tutorial on How to Compile PostgreSQL 9.5 for 
Windows 64bit

https://www.youtube.com/watch?v=-BJmuZT5IPE

It was quite difficult for me to figure it out, so hopefully it will 
make life easier for

the next guy (or gal).

--

Igal Sapir
Lucee Core Developer
Lucee.org 



Re: [GENERAL] A motion

2016-01-25 Thread Roxanne Reid-Bennett

On 1/25/2016 12:55 AM, Albe Laurenz wrote:

Regina Obe wrote:

At this point I feel we should:


...

While I personally feel that a code of conduct does not need to be an explicit
document and is something that "happens" through the way people on the lists
behave and the way the core team and list maintainers handle problems,
pgsql-general is where the community meets, and that is where such a discussion
should take place.

To a degree you have a very valid point - however wading through a 
discussion over nuanced verbiage isn't of value to me (and at least a 
few others).This discussion will not garner a visible opinion from 
the vast majority of those who read this list, and most likely, the vast 
majority of those on this list don't really care about the discussion at 
all other than not wanting the Postgres *community* to self-destruct, 
starve, or be torn apart by wolves.


From direct personal experience, separating "how to run a group" from 
"the topic" of the group improves at least the "topic" portion and those 
who actually want to participate will follow wherever the "how" moves to.


I do appreciate this community, and "everyone's" declared desire to 
maintain it's quality  a great deal - so I've piped up to add weight to 
the request for a respite from the details... I'll deal with the 
noise... by skipping it.  Adrian - a contributor.. apparently by leaving 
(at least temporarily).


Roxanne
(Returning to stealth mode...)


--
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] long transfer time for binary data

2016-01-25 Thread Johannes
Am 25.01.2016 um 19:59 schrieb Daniel Verite:
>   Johannes wrote:
> 
>> \lo_export 12345 /dev/null is completed in 0.86 seconds.
> 
> If it's an 11MB file through a 100Mbits/s network, that's
> pretty much the best that can be expected.
> 
> I would think the above is the baseline against which
> the other methods should be compared.
> 
>> I sa my images as large object, which afaik is in practise not
>> readable with a binary cursor (we should use the lo_* functions). And of
>> course I already use the LargeObjectManager of the postgresql jdbc library.
> 
> Sounds good.
> 
>> You said, the server has to convert the bytes to hex string before
>> sending it over the wire.
> 
> Only in certain contexts. SELECT lo_get(oid) is a query that returns
> bytea, so if the clients requests results in text format, they will
> be transferred as text, and it's the responsibility of the client
> to convert them back to bytes (or not, who knows, maybe the
> client wants hexadecimal).
> 
> But lo_get is an exception, and besides a late addition (9.4 I believe).
> Generally, client-side access to large objects functions doesn't
> use a client-side SQL query, it's done through the 
> "Function Call sub-protocol" described here:
> http://www.postgresql.org/docs/current/static/protocol-flow.html#AEN108750
> and the result comes back as binary.
> 
> Presumably the JDBC LargeObjectManager uses that method.
> 
> Best regards,

I thougth \lo_export can only run on server side only (like \copy copy).
0.8 seconds was the rutime on server to server disk.

Running from client (transfers only 12M):

real0m3.386s
user0m0.308s
sys 0m0.176s

Best regards Johannes



signature.asc
Description: OpenPGP digital signature


Re: [GENERAL] CoC [Final v2]

2016-01-25 Thread Chris Travers
Just to respond to Josh's previous question:

Yes, I ike the current code of conduct.  Much prefer to the alternatives
offered aimed at "feeling safe" (for the reason that keeping the peace in a
culturally diverse community will not allow people that luxury all the
time).

I am not convinced we need one, and I am worried about those who may be
moved by recent events to require one.  But I think a statement of some
kind by the core committee regarding a productive environment for all is a
good thing and this CoC fits that bill

On Mon, Jan 25, 2016 at 8:39 PM, Joshua D. Drake 
wrote:

> Hello,
>
> This thread is deprecated. The CoC Final Draft has been submitted to -core
> for final modification, acceptance or decline.
>
> Sincerely,
>
> Joshua D. Drake
>
> --
> Command Prompt, Inc.  http://the.postgres.company/
>  +1-503-667-4564
> PostgreSQL Centered full stack support, consulting and development.
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>



-- 
Best Wishes,
Chris Travers

Efficito:  Hosted Accounting and ERP.  Robust and Flexible.  No vendor
lock-in.
http://www.efficito.com/learn_more


Re: [GENERAL] A motion

2016-01-25 Thread Melvin Davidson
Although it has been previously disregarded, I would like to second the
motion that all further discussion regarding the CoC go to it's own list.

Consider this.
1. The Coc will eventually apply to ALL PostgreSQL mail lists.
2. There will be a need to have additions and revisions to the Coc.
3. As this list is for General (and mostly technical discussions) further
discussions/emails concerning the CoC only distracts from the purpose of
this email list.

On Mon, Jan 25, 2016 at 1:33 PM, Roxanne Reid-Bennett 
wrote:

> On 1/25/2016 12:55 AM, Albe Laurenz wrote:
>
>> Regina Obe wrote:
>>
>>> At this point I feel we should:
>>>
>>> ...
>>
>> While I personally feel that a code of conduct does not need to be an
>> explicit
>> document and is something that "happens" through the way people on the
>> lists
>> behave and the way the core team and list maintainers handle problems,
>> pgsql-general is where the community meets, and that is where such a
>> discussion
>> should take place.
>>
>> To a degree you have a very valid point - however wading through a
> discussion over nuanced verbiage isn't of value to me (and at least a few
> others).This discussion will not garner a visible opinion from the vast
> majority of those who read this list, and most likely, the vast majority of
> those on this list don't really care about the discussion at all other than
> not wanting the Postgres *community* to self-destruct, starve, or be torn
> apart by wolves.
>
> From direct personal experience, separating "how to run a group" from "the
> topic" of the group improves at least the "topic" portion and those who
> actually want to participate will follow wherever the "how" moves to.
>
> I do appreciate this community, and "everyone's" declared desire to
> maintain it's quality  a great deal - so I've piped up to add weight to the
> request for a respite from the details... I'll deal with the noise... by
> skipping it.  Adrian - a contributor.. apparently by leaving (at least
> temporarily).
>
> Roxanne
> (Returning to stealth mode...)
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>



-- 
*Melvin Davidson*
I reserve the right to fantasize.  Whether or not you
wish to share my fantasy is entirely up to you.


Re: [GENERAL] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Michael Paquier
On Tue, Jan 26, 2016 at 3:56 AM, Joshua D. Drake  wrote:
> On 01/25/2016 10:49 AM, Joshua Berkus wrote:
>>
>>
>>
>> - Original Message -
>>>
>>> Hi Everybody,
>>>
>>> I have posted a video tutorial on How to Compile PostgreSQL 9.5 for
>>> Windows 64bit
>>> https://www.youtube.com/watch?v=-BJmuZT5IPE
>>>
>>> It was quite difficult for me to figure it out, so hopefully it will
>>> make life easier for
>>> the next guy (or gal).
>>
>>
>> Wow, thanks for doing that!
>>
>
> Yes, no doubt. Can we get this linked somewhere so we don't lose it?

Here would be fine, no?
https://wiki.postgresql.org/wiki/Detailed_installation_guides
There is a section for Windows.
-- 
Michael


-- 
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Joshua D. Drake

On 01/25/2016 05:29 PM, Michael Paquier wrote:

On Tue, Jan 26, 2016 at 3:56 AM, Joshua D. Drake  wrote:

On 01/25/2016 10:49 AM, Joshua Berkus wrote:




- Original Message -


Hi Everybody,

I have posted a video tutorial on How to Compile PostgreSQL 9.5 for
Windows 64bit
https://www.youtube.com/watch?v=-BJmuZT5IPE

It was quite difficult for me to figure it out, so hopefully it will
make life easier for
the next guy (or gal).



Wow, thanks for doing that!



Yes, no doubt. Can we get this linked somewhere so we don't lose it?


Here would be fine, no?
https://wiki.postgresql.org/wiki/Detailed_installation_guides
There is a section for Windows.


Yeah probably. I don't have wiki editing privs though.

JD






--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
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] Tutorial on How to Compile PostgreSQL 9.5 for Windows 64bit

2016-01-25 Thread Michael Paquier
On Tue, Jan 26, 2016 at 10:34 AM, Joshua D. Drake  
wrote:
> On 01/25/2016 05:29 PM, Michael Paquier wrote:
>>
>> On Tue, Jan 26, 2016 at 3:56 AM, Joshua D. Drake 
>> wrote:
>>>
>>> On 01/25/2016 10:49 AM, Joshua Berkus wrote:




 - Original Message -
>
>
> Hi Everybody,
>
> I have posted a video tutorial on How to Compile PostgreSQL 9.5 for
> Windows 64bit
> https://www.youtube.com/watch?v=-BJmuZT5IPE
>
> It was quite difficult for me to figure it out, so hopefully it will
> make life easier for
> the next guy (or gal).



 Wow, thanks for doing that!

>>>
>>> Yes, no doubt. Can we get this linked somewhere so we don't lose it?
>>
>>
>> Here would be fine, no?
>> https://wiki.postgresql.org/wiki/Detailed_installation_guides
>> There is a section for Windows.
>
>
> Yeah probably. I don't have wiki editing privs though.

A community account should be enough, but never mind, I have added it.
-- 
Michael


-- 
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] request for comment re "contributor-covenant.org"

2016-01-25 Thread Joshua D. Drake

Zenaan,

Thank you for providing your insight. However, our Core Committee is 
already considering a CoC and is in final stages of either modification, 
acceptance or decline.


Sincerely,

Joshua D. Drake

--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] request for comment re "contributor-covenant.org"

2016-01-25 Thread Zenaan Harkness
Warning, some people may consider the following analysis to have one
or two trigger words and or to be insensitive.

DO NOT read it if you are emotionally sensitive or otherwise
challenged in regards to robust communications and the rights of
amateur humans to create social spaces of their choosing.

In principle, the concept of a "contributor covenant" sounds sensible,
but my version of such a covenant would clearly be quite different to
the one at http://contributor-covenant.org and the below is a very
rough second draft (after having run it past a few friends off list)
attempt at a response to that website's front page. Such a "covenant"
worthy of the name would need a lot more work which I have not done.

Also, I feel that it is important that certain things so far unsaid
regarding c-c.org, ought be raised for discussion, although my version
of raising discussion is unfortunately most likely to be
controversial, so in general, unless you wish to pick the eyes and
distill what I am struggling to say, don't read the below as it will
likely be too much work for you - if there's the slightest chance you
might take offense, this email is not for you.


Since the contributor-covenant.org got referenced, and I seem to
remember reading allegedly 1000's of "open source projects" have
"adopted" it, and there appears to quite the campaign to "encourage"
the PostgreSQL project to likewise adopt that particular agreement, I
figured it was time to read it and see what all the fuss is about.

Those who chaperone more than one "open source" project mailing lists
may wish to bring themselves up to speed with this so-called
"covenant" before the steamroller hits your group/ list/ community,
since it seems inevitable at this point.

The below is my second woeful attempt (the first being private off
list) to bring some sanity to the "covenant" discussion. It needs your
improvements.

I have put ">>" to readily distinguish text coming from c-c.org

Good luck,
Zenaan


http://contributor-covenant.org/

>> Contributor Covenant
>> A Code of Conduct for Open Source Projects.

Sounds reasonable.


>> Open Source has always been a foundation of the Internet, and with the advent
>> of social open source networks this is more true than ever.

Let's hope free libre and open source software - FLOSS, stays as the foundation
of the Internet!

"social open source networks" - what?? Facebook social network??

Use of new terminology, without explaining that terminology, and
presuming it is known and well understood terminology, in a document
you are pushing as a new and additional "social contract" which others
are pressed upon to adopt and enforce, is IMHO passive aggressive.


>> But free, libre, and open source projects suffer from a startling lack of
>> diversity, with dramatically low participation by women, people of color, and
>> other marginalized populations.

Those who have an interest in promoting, assisting, sponsoring and generally
facilitating "the diversity" within this particular libre software
project or mailing list,
are welcome to do so and in general, ought be supported to the extent that their
actions and words are neither actively nor passively aggressive towards any
member of this mailing list, and are actually supportive of the
technical goals of
this project.


>> Part of this problem

Lack of diversity may be viewed as a problem.

Such a viewpoint is a personal, individual matter. Your personal, individual
opinion on this matter may be discussed, but in general is off topic for this
mailing list.

Speaking or writing that "lack of diversity is a problem", and even moreso,
building the presumption into the words of a so-called "social covenant", where
that presumption is almost hidden and "not up for debate", is a passive
aggressive approach to communication with others who may or may not
disagree with this position.

Passive aggressive communication is not welcome on this mailing list.


>> lies with the very structure of some projects:

What is "the very structure of a project"? This phrase is too generic, and not
explained, despite the next part of that sentence which follows below, which
appears to pretend to answer (or define) the phrase - it does not.

Phrases and terminologies used out of context and having indefinite and vague
meanings, is a sign of passive aggressive communication and all
members of this mailing list are encourage to ridicule such
communication.


>> the use of insensitive language, thoughtless use of pronouns, assumptions of
>> gender, and even sexualized or culturally insensitive names.

Although certain social niceties are encouraged on this mailing list, they are
not required and indeed firm, clear and precise languaging is valued and
encouraged.

If you are overly sensitive, or in need (or desire) of an emotionally sensitive
environment, then consider another mailing list - this mailing list is likely
not for you, and if you are in need of any professional help, you are 

Re: [GENERAL] Performance options for CPU bound multi-SUM query

2016-01-25 Thread Andreas Kretschmer
Matt  wrote:

> I have a warehousing case where data is bucketed by a key of an hourly
> timestamp and 3 other columns. In addition there are 32 numeric columns. The
> tables are partitioned on regular date ranges, and aggregated to the lowest
> resolution usable.
> 
> The principal use case is to select over a range of dates or hours, filter by
> the other key columns, and SUM() all 32 of the other columns. The execution
> plan shows the primary key index limits row selection efficiently, but the
> query appears CPU bound in performing all of those 32 SUM() aggregates.
> 
> I am looking at a couple of distributed PostgreSQL forks, but until those 
> reach
> feature parity with 9.5 I am hoping to stay with single node PostgreSQL.
> 
> Are there any other options I can use to improve query times?

Maybe cybertec's agg() - patch, see
http://www.cybertec.at/postgresql_produkte/agg-parallele-aggregierungen-fuer-postgresql/

(and ask Hans for an english docu!)

But, i see, it needs 9.5.


Andreas
-- 
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect.  (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly."   (unknown)
Kaufbach, Saxony, Germany, Europe.  N 51.05082°, E 13.56889°


-- 
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] TABLESAMPLE usage

2016-01-25 Thread Tom Smith
Thanks, the solution would work for fixed interval timestamp.
But the data I am dealing with has irregular timestamp so can not be
generated with exact steps.

I would consider this a special case/method of random sampling, evenly
distributed sampling according to the defined  timestamp index.

On Mon, Jan 25, 2016 at 3:48 AM, Vik Fearing  wrote:

> On 01/25/2016 05:09 AM, Tom Smith wrote:
> > Hello:
> >
> > I have a big table with that is always appended with new data with a
> unique
> > sequence id  (always incremented, or timestamp as unique index) each row.
> > I'd like to sample, say 100 rows out of say 1000 rows evently across all
> > the rows,
> > so that it would return  rows  of1, 101, 201, 301you get idea.
> > can TABLESAMPLEget one row for every 100 rows, based on the order
> > of the rows added to table using the timestamp as already indexed/sorted
> > sequence
>
> No, TABLESAMPLE is intended to take a random sampling of the data using
> various methods.
>
> You're looking for something more like this:
>
> select t.*
> from generate_series(1, (select max(id) from t), 100) g
> join t on t.id = g;
> --
> Vik Fearing  +33 6 46 75 15 36
> http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
>


Re: [GENERAL] Performance options for CPU bound multi-SUM query

2016-01-25 Thread David Rowley
On 25 January 2016 at 15:45, Matt  wrote:
> I have a warehousing case where data is bucketed by a key of an hourly
> timestamp and 3 other columns. In addition there are 32 numeric columns. The
> tables are partitioned on regular date ranges, and aggregated to the lowest
> resolution usable.
>
> The principal use case is to select over a range of dates or hours, filter
> by the other key columns, and SUM() all 32 of the other columns. The
> execution plan shows the primary key index limits row selection efficiently,
> but the query appears CPU bound in performing all of those 32 SUM()
> aggregates.
>

SUM(numeric) also has to work quite a bit harder than an an aggregate
like sum(float8) too since the addition in numeric is implemented in
software.
It depends on the use case, but for some cases the float4 or float8
types might be an option and it will offer much faster aggregation.
There is also https://github.com/2ndQuadrant/fixeddecimal which may be
of some use if you need fixed precision up to a predefined scale. We
found that using fixeddecimal instead of numeric for the TPC-H
benchmark improved performance of query 1 significantly.

-- 
 David Rowley   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
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] TABLESAMPLE usage

2016-01-25 Thread Vik Fearing
On 01/25/2016 05:09 AM, Tom Smith wrote:
> Hello:
> 
> I have a big table with that is always appended with new data with a unique
> sequence id  (always incremented, or timestamp as unique index) each row.
> I'd like to sample, say 100 rows out of say 1000 rows evently across all
> the rows,
> so that it would return  rows  of1, 101, 201, 301you get idea.
> can TABLESAMPLEget one row for every 100 rows, based on the order
> of the rows added to table using the timestamp as already indexed/sorted
> sequence

No, TABLESAMPLE is intended to take a random sampling of the data using
various methods.

You're looking for something more like this:

select t.*
from generate_series(1, (select max(id) from t), 100) g
join t on t.id = g;
-- 
Vik Fearing  +33 6 46 75 15 36
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support


-- 
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] A motion

2016-01-25 Thread Albe Laurenz
Regina Obe wrote:
> At this point I feel we should:
> 
> a) Move this to pgsql-advocacy [...]

> Or
> 
> b) Start a new PostgreSQL mailing list - call it -  pgsql-coc.

-1

While I personally feel that a code of conduct does not need to be an explicit
document and is something that "happens" through the way people on the lists
behave and the way the core team and list maintainers handle problems,
pgsql-general is where the community meets, and that is where such a discussion
should take place.

If it annoys some people, so be it; if people express their dislike, that's
a statement as well.  A code of conduct is about non-technical implications
of activity on the mailing lists, so using the non-technical nature of this
discussion as a reason to push it off the radar is counter-productive.

Yours,
Laurenz Albe

-- 
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] TABLESAMPLE usage

2016-01-25 Thread Matija Lesar
On 25 January 2016 at 09:55, Tom Smith  wrote:

> Thanks, the solution would work for fixed interval timestamp.
> But the data I am dealing with has irregular timestamp so can not be
> generated with exact steps.
>
> I would consider this a special case/method of random sampling, evenly
> distributed sampling according to the defined  timestamp index.
>
> On Mon, Jan 25, 2016 at 3:48 AM, Vik Fearing  wrote:
>
>> On 01/25/2016 05:09 AM, Tom Smith wrote:
>> > Hello:
>> >
>> > I have a big table with that is always appended with new data with a
>> unique
>> > sequence id  (always incremented, or timestamp as unique index) each
>> row.
>> > I'd like to sample, say 100 rows out of say 1000 rows evently across all
>> > the rows,
>> > so that it would return  rows  of1, 101, 201, 301you get idea.
>> > can TABLESAMPLEget one row for every 100 rows, based on the order
>> > of the rows added to table using the timestamp as already indexed/sorted
>> > sequence
>>
>> No, TABLESAMPLE is intended to take a random sampling of the data using
>> various methods.
>>
>> You're looking for something more like this:
>>
>> select t.*
>> from generate_series(1, (select max(id) from t), 100) g
>> join t on t.id = g;
>> --
>> Vik Fearing  +33 6 46 75 15 36
>> http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
>>
>
>

Hi,

you can accomplish this with row_number()

:

WITH data_cte as (
SELECT
id,
clock_timestamp() as ctimestamp
FROM generate_series(1,1000) as id
)
SELECT
*
FROM
(SELECT
id,
ctimestamp,
row_number() OVER (ORDER BY ctimestamp) as rownum
FROM data_cte
) as data_withrownumbers
WHERE
rownum%100=1;

Bye,
Matija Lesar


Re: [GENERAL] TABLESAMPLE usage

2016-01-25 Thread Vik Fearing
On 01/25/2016 09:55 AM, Tom Smith wrote:
> Thanks, the solution would work for fixed interval timestamp.
> But the data I am dealing with has irregular timestamp so can not be
> generated with exact steps.
> 
> I would consider this a special case/method of random sampling, evenly
> distributed sampling according to the defined  timestamp index.

You could probably create your own sampling method to do what you want.

See contrib modules tsm_system_rows and tsm_system_time for guidance.
http://www.postgresql.org/docs/current/static/tsm-system-rows.html
http://www.postgresql.org/docs/current/static/tsm-system-time.html
-- 
Vik Fearing  +33 6 46 75 15 36
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support


-- 
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] Possible to dump/load a database from within psql?

2016-01-25 Thread Joshua D. Drake

On 01/25/2016 02:16 AM, Brian Cardarella wrote:

Is it possible, and if so how, to dump and then load a database to/from
a file from within a psql connection?


pg_dump -h $host -U $user $database|psql -U $user -h $host $database

http://www.postgresql.org/docs/9.5/static/app-pgdump.html

Sincerely,

JD


--
Command Prompt, Inc.  http://the.postgres.company/
 +1-503-667-4564
PostgreSQL Centered full stack support, consulting and development.


--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Possible to dump/load a database from within psql?

2016-01-25 Thread Brian Cardarella
Is it possible, and if so how, to dump and then load a database to/from a
file from within a psql connection?

--
Brian Cardarella
CEO of DockYard
Visit us: http://dockyard.com
Call us: (855) DOCK-YRD
Follow me on Twitter: http://twitter.com/bcardarella
Follow us on Twitter: http://twitter.com/DockYard


Re: [GENERAL] Possible to dump/load a database from within psql?

2016-01-25 Thread Raymond O'Donnell
On 25/01/2016 10:16, Brian Cardarella wrote:
> Is it possible, and if so how, to dump and then load a database to/from
> a file from within a psql connection?

You can use the COPY command to do a table at a time, but you'll get
just the data - you won't get permissions etc.

Ray.

-- 
Raymond O'Donnell :: Galway :: Ireland
r...@iol.ie


-- 
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] TABLESAMPLE usage

2016-01-25 Thread Simon Riggs
On 25 January 2016 at 09:44, Matija Lesar  wrote:


> you can accomplish this with row_number()
> 
> :
>
> WITH data_cte as (
> SELECT
> id,
> clock_timestamp() as ctimestamp
> FROM generate_series(1,1000) as id
> )
> SELECT
> *
> FROM
> (SELECT
> id,
> ctimestamp,
> row_number() OVER (ORDER BY ctimestamp) as rownum
> FROM data_cte
> ) as data_withrownumbers
> WHERE
> rownum%100=1;
>

You can, but its not very fast.

-- 
Simon Riggshttp://www.2ndQuadrant.com/

PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services