Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread David Rowley
On 18 April 2016 at 13:10, Sergei Agalakov wrote: > Thank you, I know this place. > I just wanted to check that my request will have the peoples support. > So far it doesn't. It looks like that or people never need to compare two PG > databases to find the differences in the schemas or security, >

[GENERAL] How to detoast a column of type BYTEAOID

2016-04-17 Thread david
I am attempting to create a new language implementation. The language is Andl (andl.org), so the handler is plandl. I am having a bit of trouble executing SPI queries from inside plandl. The particular problem arises after calling SPI_cursor_fetch() and then SPI_getbinval() on a column of type BY

Re: [GENERAL] $foo $bar is BAD

2016-04-17 Thread Gavin Flower
On 16/04/16 14:00, Peter Devoy wrote: Although people commonly use $foo $bar in examples, it is actually a misuse of a VERY rude acronym. The next time you need to make an example, please try being a little more original (or meaningful) with your variable names. In light of recent CoC decision

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Sergei Agalakov
Thank you, I know this place. I just wanted to check that my request will have the peoples support. So far it doesn't. It looks like that or people never need to compare two PG databases to find the differences in the schemas or security, or happy to use the third party tools to do it, and don't

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Sergei Agalakov
Nobody asks for pg_dump to be a schema comparison tool. As you tell yourself it is a most reliable schema capturing tool. All I am asking is that if pg_dump is executed on two databases with the identical schemas and security it should be able to produce the identical SQL dumps of these schemas

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Melvin Davidson
fyi, if you have a feature request or enhancement, then the proper place for that is here -> https://postgresql.uservoice.com/forums/21853-general On Sun, Apr 17, 2016 at 8:26 PM, Sergei Agalakov < sergei.agala...@getmyle.com> wrote: > I hardly can see that a sorting of the grants by users will

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Sergei Agalakov
I hardly can see that a sorting of the grants by users will create a measurable impact on the pg_dump performance in a real database. One can imaging a database with tens of thousands of objects and tens of thousands of users and almost no data, but it would be quite unusual. Anyway, if a sorting

Re: [GENERAL] SAN - Same array Master-Slave

2016-04-17 Thread John R Pierce
On 4/17/2016 3:21 PM, drum.lu...@gmail.com wrote: Can I use the same SAN array to a Master and a Slave server? as long as they are different logical volumes on the SAN, sure. of course that SAN will be dealing with the IO load from both servers, and the SAN itself could be a single point of

[GENERAL] SAN - Same array Master-Slave

2016-04-17 Thread drum.lu...@gmail.com
Hi all, Currently, I have four servers: - 1 Master server - 1 Slave server (read-only) - 2 Slaves servers (hot_standby) We're having I/O and size issue, currently running SATA disks. So we'll need to change our disks to SAN. *Question:* Can I use the same SAN array to a Master and

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Adrian Klaver
On 04/17/2016 01:58 PM, Adrian Klaver wrote: On 04/17/2016 01:10 PM, Sergei Agalakov wrote: I don't see how these questions are related to the proposed pg_dump improvement. I suggest to improve pg_dump so it can be used instead of the third party tools like DBSteward and SQLWorkbench/J etc. to c

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Adrian Klaver
On 04/17/2016 01:10 PM, Sergei Agalakov wrote: I don't see how these questions are related to the proposed pg_dump improvement. I suggest to improve pg_dump so it can be used instead of the third party tools like DBSteward and SQLWorkbench/J etc. to compare two different databases or existing dum

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Adrian Klaver
On 04/17/2016 01:10 PM, Sergei Agalakov wrote: I don't see how these questions are related to the proposed pg_dump improvement. I suggest to improve pg_dump so it can be used instead of the third party tools like DBSteward and SQLWorkbench/J etc. to compare two different databases or existing dum

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Bill Moran
On Sun, 17 Apr 2016 14:10:50 -0600 Sergei Agalakov wrote: > I don't see how these questions are related to the proposed pg_dump > improvement. > I suggest to improve pg_dump so it can be used instead of the third > party tools like DBSteward and SQLWorkbench/J etc. > to compare two different da

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Sergei Agalakov
I don't see how these questions are related to the proposed pg_dump improvement. I suggest to improve pg_dump so it can be used instead of the third party tools like DBSteward and SQLWorkbench/J etc. to compare two different databases or existing dumps, and to identify the differences. The use c

Re: [GENERAL] pg_basebackup: return value 1: reason?

2016-04-17 Thread Andrej Vanek
Hello Adrian, I tried to use -U without "su"- launched directly by root: same behaviour. Finally I reverted my script to use standard backup (pg_start_backup; rsync; pg_stop_backup)- this works- the only downside is possible collisions with on-line backup/synchronizaiton of other two nodes on mast

Re: [GENERAL] 20160417105248.d20dcefed39b5d9031c6b...@potentialtech.com

2016-04-17 Thread Rob Sargent
> On Apr 17, 2016, at 12:41 PM, Sergei Agalakov > wrote: > > I know about DBSteward. I don't like to bring PHP infrastructure only to be > able to compare two dumps, > and to deal with potential bugs in the third party tools. The pg_dump in > other hand is always here, and is always trusted.

[GENERAL] 20160417105248.d20dcefed39b5d9031c6b...@potentialtech.com

2016-04-17 Thread Sergei Agalakov
I know about DBSteward. I don't like to bring PHP infrastructure only to be able to compare two dumps, and to deal with potential bugs in the third party tools. The pg_dump in other hand is always here, and is always trusted. SQLWorkbench/J also can compare two schemas, and requires only Java. A

[GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Sergei Agalakov
It can be done of course, but as you can see in my examples the statements in pg_dump generated scripts are grouped together by the objects. It is easier to analyze the differences when all these differences for an object are clustered together, and aren't dispersed in the diff file. It also wil

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Bill Moran
On Sat, 16 Apr 2016 13:33:21 -0600 Sergei Agalakov wrote: > Hi, > > Currently as in PG 9.4, 9.5 the order of the statements in the script > produced by pg_dump is uncertain even for the same versions of the > databases and pg_dump. > One database may script grants like > > REVOKE ALL ON TABLE

Re: [GENERAL] $foo $bar is BAD

2016-04-17 Thread Joshua D. Drake
On 04/15/2016 04:35 PM, Melvin Davidson wrote: *Although people commonly use $foo $bar in examples, it is actually a misuse of a VERY rude acronym. Actually it isn't. *The next time you need to make an example, please try being a little more original (or meaningful) with your variable names.

Re: [GENERAL] Multimaster

2016-04-17 Thread Craig Ringer
On 14 April 2016 at 17:11, Moreno Andreo wrote: > All databases that have to be replicated have a flag in the app > configuration, and the replication config is set up, for each database and > each site, when the first synchronization is made, so we could spawn a > process per database and repli

Re: [GENERAL] Multimaster

2016-04-17 Thread Craig Ringer
On 14 April 2016 at 17:14, konstantin knizhnik wrote: > > On Apr 14, 2016, at 8:41 AM, Craig Ringer wrote: > > On 1 April 2016 at 19:50, Konstantin Knizhnik > wrote: > > Right now the main problem is parallel apply: we need to apply changes >> concurrently to avoid unintended dependencies causin

Re: [GENERAL] Enhancement request for pg_dump

2016-04-17 Thread Karsten Hilbert
On Sat, Apr 16, 2016 at 01:33:21PM -0600, Sergei Agalakov wrote: > Currently as in PG 9.4, 9.5 the order of the statements in the script > produced by pg_dump is uncertain even for the same versions of the databases > and pg_dump. > One database may script grants like > > REVOKE ALL ON TABLE cont

Re: [GENERAL] understanding postgres backend process memory usage

2016-04-17 Thread Jony Cohen
Hi David, How many different table/objects do you read from and do you use bind variables? Each postmaster process keeps internal dictionary on objects and queries ran - If you have too many objects or queries planned you might take up too much ram. If this is indeed your situation, you might bene

[GENERAL] what's the exact command definition in read committed isolation level?

2016-04-17 Thread Jinhua Luo
Hi All, The document said, "Read Committed mode starts each command with a new snapshot that includes all transactions committed up to that instant". But what about the embedded commands within the outer command itself? Do they share the same snapshot with the outer command? a) trigger This is