[GENERAL] pg_rewind issue

2017-09-17 Thread James Sewell
+ As 00150C7300A9 > 00150C740044 I'm confused why this WAL would be required? It's never been created on either server (although the same suffix does exist in timeline 14). Cheers, James Sewell (1) /usr/edb/as9.6/bin/pg_rewind --target-pgdata=/ppas/9.6/data/pg_data --source-server=

[GENERAL] pg_rewind issue

2017-09-07 Thread James Sewell
or archive management, which works fine the rest of the time. Can anyone think of a way this could be happening? Are we missing a step above? Cheers, James Sewell, -- -- The contents of this email are confidential and may be subject to legal or professional privilege and

Re: [GENERAL] Interesting streaming replication issue

2017-08-02 Thread James Sewell
_HINT records. Any ideas? Cheers, James James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+61) 2 8099 9099 <(+61)%202%208099%209000

Re: [GENERAL] Interesting streaming replication issue

2017-07-27 Thread James Sewell
e log not only are they there, the standby has already retrieved them. It's then asking for the log again via the stream. -- James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 *W* www.jirotech.com

Re: [GENERAL] Interesting streaming replication issue

2017-07-26 Thread James Sewell
; Although you are right - that would almost make sense if I had done that! Cheers, James > > Regards, > > Gunnar "Nick" Bluth > > Am 27. Juli 2017 05:00:17 MESZ schrieb James Sewell < > james.sew...@jirotech.com>: > >> Hi all, >> >> I&

[GENERAL] Interesting streaming replication issue

2017-07-26 Thread James Sewell
sing something here, this seems very odd. One thing I have noticed is it only seems to be caused after a lot of WAL is produced and the pg_xlog directory is sitting at max_wal_size James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 20

Re: [GENERAL] Generalized pg_stat_statements?

2017-05-03 Thread James Sewell
ments gets above this number you lose information. To increase max you'd need a restart, which isn't ideal but I can't see any way round that. It wouldn't help you much - but it would be great for monitoring if there was a pg_stat_statements_agg table which presented total co

[GENERAL] Logical slot preservation after physical failover

2017-04-27 Thread James Sewell
oy feature in Enterprise (where HA clustering is the general rule), as it always comes with a high possibility of data loss. This is compounded as it seems logical replication sends transactions in sequence (ie xid 2 blocks xid 3 until it commits). Any thoughts / hints / hacks? Cheers, Jam

Re: [GENERAL] PostgreSQL corruption

2017-02-16 Thread James Sewell
Sadly this is for a customer who has 3000 of these in the field, the raid controller is on the motherboard. At least they know where to point the finger now! Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P

Re: [GENERAL] PostgreSQL corruption

2017-02-14 Thread James Sewell
lying. Breaking up the RAID and re-imaging with JBOD dropped this to 50 ops/sec - another question but still looking like a real result. So in this case it looks like the RAID controller wasn't disabling caching as advertised. Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect

Re: [GENERAL] PostgreSQL corruption

2017-02-14 Thread James Sewell
it. A C one would be the best I suppose as it could exactly mimic PostgreSQL. Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+

[GENERAL] PostgreSQL corruption

2017-02-13 Thread James Sewell
9.5 stable with checksums Can anyone think of anything else we should be considering / testing / factoring in? Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%2080

Consider pgmodeler - Re: [GENERAL] Data Modeling Tools - Version specific to Postgres

2017-02-02 Thread James Bullock
On 02/01/2017 01:35 PM, Greg Slawek wrote: > > Can anyone recommend a data modeling tool (preferably Mac OSX compatible)? > > I would like to be sure it can export version specific SQL code (ie 9.1 vs > 9.4) > I'm very happy with pgmodeler, which I picked up about 6-8 weeks ago. It's an open

Re: [GENERAL] How well does PostgreSQL 9.6.1 support unicode?

2016-12-21 Thread James Zhou
orrectly, so does substring() function. Thank you all for help. James On Wed, Dec 21, 2016 at 8:31 AM, Tom Lane wrote: > Vick Khera writes: > > On Wed, Dec 21, 2016 at 2:56 AM, Kyotaro HORIGUCHI < > > horiguchi.kyot...@lab.ntt.co.jp> wrote: > >> A PostgreSQL dat

Re: [GENERAL] How well does PostgreSQL 9.6.1 support unicode?

2016-12-20 Thread James Zhou
eturns the correct values for all supported unicode chars. Correct sorting is nice-to-have. Any help to get unicode chars, particularly the mojos (0x1F478, 0x1F479), in and out of pg correctly is much appreciated. Thank you! James On Tue, Dec 20, 2016 at 9:24 PM, Tom Lane wrote: > James

[GENERAL] How well does PostgreSQL 9.6.1 support unicode?

2016-12-20 Thread James Zhou
. - Their lengths in character are not correct - they are not retrieved correctly, judged by the their fetched ascii value (column 5 in the table above) - substring is not correct Specifically, the lack of support for emojo characters 0x1F478, 0x1F479 is causing a problem in my application. My conclusion: - PostgreSQL 9.6.1 only supports a subset of unicode characters in BMP. Is there any documents defining which subset is fully supported? Are any configuration I can change so that more unicode characters are supported? Thanks James

Re: [GENERAL] Where to download pgbench for Windows 7

2016-12-03 Thread James Zhou
Thank you, John. On Dec 2, 2016 23:12, "John R Pierce" wrote: > On 12/2/2016 10:37 PM, James Zhou wrote: > >> I am new to PostgreSQL and am leaning it. I installed PostgreSQL on a >> Windows 7 laptop and would like to play with pgbench to generate a sample >> d

[GENERAL] Where to download pgbench for Windows 7

2016-12-02 Thread James Zhou
1] Is there a Windows version of pgbench, or it is only available on Linux? Thanks James

Re: [GENERAL] Sequential parallel scan / agg

2016-11-13 Thread James Sewell
ontains a data-modifying >operation either at the top level or within a CTE, no parallel plans for >that query will be generated. This is a limitation of the current >implementation which could be lifted in a future release. > > Sad, but looks to hold from this testing!

Re: [GENERAL] Sequential parallel scan / agg

2016-11-13 Thread James Sewell
Hi, Yes, same result (non-parallel seq scan) Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+61) 2 8099 9099 <(+61)%2

[GENERAL] Sequential parallel scan / agg

2016-11-13 Thread James Sewell
00:00'::timestamp without time zone)) -> Parallel Seq Scan on meter_read_2016_03_29 mr_1 (cost=0.00..3756417.28 rows=23280094 width=0) Filter: ((timestamp_rounded >= '2016-03-28 00:00:00'::timestamp without time zone) AND (timestamp_roun

[GENERAL] "The index is not optimal" GiST warnings

2016-10-13 Thread James Robinson
web / mailing list archives finds little to nothing regarding "The index is not optimal. To optimize it, contact a developer, or try to use the column as the second one in the CREATE INDEX command." Should we make the effort to track down these indices / constraints and reorder the columns to put the original table's primary key fields first, then the range column last? -- James Robinson Socialserve.com by Emphasys Software

Re: [GENERAL] Foreign key against a partitioned table

2016-08-23 Thread Craig James
On Tue, Aug 23, 2016 at 1:07 PM, Igor Neyman wrote: > > > *From:* pgsql-general-ow...@postgresql.org [mailto:pgsql-general-owner@ > postgresql.org] *On Behalf Of *Craig James > *Sent:* Tuesday, August 23, 2016 4:00 PM > *To:* pgsql-general@postgresql.org > *Subject:*

[GENERAL] Foreign key against a partitioned table

2016-08-23 Thread Craig James
How do you create a foreign key that references a partitioned table? I'm splitting a large table "molecules" into 20 partitions, which also has an associated "molecular_properties" table. It looks something like this (pseudo-code): create table molecules(molecule_idinteger primary key,

Re: [GENERAL] Critical failure of standby

2016-08-17 Thread James Sewell
Hi, No, this was a one off in a network split situation. I'll check the startup when I get a chance - thanks for the help. Cheers, James Sewell, Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209

Re: [GENERAL] Critical failure of standby

2016-08-16 Thread James Sewell
Hey Sameer, As per the logs there was a crash of one standby, which seems to have corrupted that standby and the two cascading standby. - No backups - Full page writes enabled - Fsync enabled Cheers, James Sewell, Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road

Re: [GENERAL] Critical failure of standby

2016-08-15 Thread James Sewell
again. Cheers, James Sewell, Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+61) 2 8099 9099 <(+61)%202%208099%209000> On Tue, Aug 16, 2016 at 12:36 PM, John R Pierc

Re: [GENERAL] Critical failure of standby

2016-08-15 Thread James Sewell
ion though right? - it's just not getting WALs. Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+61) 2 8099 9099 <(+61)%20

Re: [GENERAL] Critical failure of standby

2016-08-14 Thread James Sewell
rvers?. Here is a link to a diagram of the current environment: http://imgur.com/a/MoKMo I'll look into patching for a core-dump. Cheers, James Sewell, Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%2

Re: [GENERAL] Critical failure of standby

2016-08-12 Thread James Sewell
Hello, I double posted this (posted once from an unregistered email and assumed it would be junked). I'm continuing all discussion on the other thread now. Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 20

Re: [GENERAL] Critical failure of standby

2016-08-12 Thread James Sewell
anything abnormal I think the key looks like the (legitimate) loss of network to the Prod master, then: (0:XX000)FATAL: invalid memory alloc request size 3445219328 Everything seems to go wrong from there. Are WAL segments checked for integrity once they are received? James Sewell, PostgreSQL

[GENERAL] Critical failure of standby

2016-08-12 Thread James Sewell
the standby? Cheers, James Sewell, Solutions Architect Suite 112, Jones Bay Wharf, 26-32 Pirrama Road, Pyrmont NSW 2009 *P *(+61) 2 8099 9000 <(+61)%202%208099%209000> *W* www.jirotech.com *F * (+61) 2 8099 9099 <(+61)%202%208099%209000> -- -- The content

[GENERAL] Standby crash

2016-08-11 Thread James Sewell
choose an earlier recovery target. Does anyone have any ideas? It looks to me like some sort of bug / error with the replication protocol or maybe some corruption on the master which wasn't noticed and fed across? If that's the case would checksums help here? Are the computed on the stan

Re: [GENERAL] Uber migrated from Postgres to MySQL

2016-07-28 Thread James Keener
If we're talking about favourite bug https://bugs.mysql.com/bug.php?id=21153 is mine Join with many tables hangs mysql (and taking 100% cpu) > Description: > the following query hangs the mysql server taking 100% cpu. also an > "explain" of the query hangs the server! It's "not a bug" because yo

Re: [GENERAL] Uber migrated from Postgres to MySQL

2016-07-27 Thread James Keener
So, millions is a lot, but it's not difficult to get to a place where you have thousands or tables. Image a case in which census data and the associated geometries. https://github.com/censusreporter/census-postgres has 22 surveys, each with 230+ tables. That's 5000+ tables right there. Now, the T

Re: [GENERAL] GRANTable Row Permissions

2016-07-03 Thread James Keener
Of course I think of something as soon as I send it. Policies can be granted to a specific role! So create policy xx on table_1 for select to role_1 using (row_id = 1234); Jim On Sun, Jul 3, 2016 at 12:26 PM, James Keener wrote: > I'm trying to work out how to grant permissions

[GENERAL] GRANTable Row Permissions

2016-07-03 Thread James Keener
I'm trying to work out how to grant permissions to rows in a table without having to rebuild the pg auth mechanisms (see below). One option is to have many tables (each representing a row), and grant normally. The other is, like I build below, uses a table and a recursive CTE to resolve the PG grou

Re: [GENERAL] PostgresSQL and HIPAA compliance

2016-06-17 Thread James Keener
The method you use to store the data is irrelevant. Access to your network. Logging. If you're encrypting the disk. How is the application presenting this data. What kind of ACLs are you using. Asking if PG is good to store HIPAA data is exactly as useful as asking if you can even store HIPAA data.

Re: [GENERAL] Way to get at parsed trigger 'WHEN' clause expression?

2016-03-25 Thread James Robinson
> On Mar 25, 2016, at 3:02 PM, Igor Neyman wrote: > > James, > > Instead of pg_catalog, you could use INFORMATION_SCHEMA to get "WHEN" clause: > > select action_condition from information_schema.triggers where trigger_name = > 'your_trigger_name'

Re: [GENERAL] Way to get at parsed trigger 'WHEN' clause expression?

2016-03-25 Thread James Robinson
HEN clause portion' for this use case (an in-house web-based schema browser which just got taught how to display triggers). Was primarily interested in seeing if there was a known way of doing this short of filthy string parsing. I'll post the soln. I end up with just for mail archives

[GENERAL] Way to get at parsed trigger 'WHEN' clause expression?

2016-03-24 Thread James Robinson
ilt in, or should we just make call to pg_catalog.pg_get_triggerdef() and parse out the WHEN clause text? Thanks! -- James Robinson Socialserve.com by Emphasys Software -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscrip

Re: [GENERAL] Unique UUID value - PostgreSQL 9.2

2016-03-14 Thread James Keener
Is a uuid a valid value in the application making use of the data? Why can't you add the column to table b and then import, or use create the uuid in the import select clause? I'm also having trouble understanding the problem and why you've discounted the options you've not even told us you've c

Re: [GENERAL] BDR

2016-03-14 Thread James Keener
Also, what did you run exactly (sanitized of course). On March 14, 2016 5:38:19 PM EDT, John R Pierce wrote: >On 3/14/2016 2:17 PM, Dustin Kempter wrote: >> However my instances are not on the same server and I attempted to >> simply add a host=(the ip) but that failed. Please help > >did you g

Re: [GENERAL] retrieve grouping sets/rollup rows

2016-03-13 Thread James Keener
/me has learned something new! Thanks! On 03/13/2016 10:44 PM, Tom Lane wrote: >>> On 03/13/2016 10:07 PM, Tom Smith wrote: It would help if the resultset has some param to mark which is which with the grouping sets index. > > I think you're looking for the GROUPING() function. See >

Re: [GENERAL] retrieve grouping sets/rollup rows

2016-03-13 Thread James Keener
It just dawned on me that you may note have meant having them in a specific sequence in the result set. Even still, I think it's much more clear being explicit with what rows are included and which aren't. Jim On 03/13/2016 10:12 PM, James Keener wrote: > Why? You're already

Re: [GENERAL] retrieve grouping sets/rollup rows

2016-03-13 Thread James Keener
resultset has some param to mark which is which > with the grouping sets index. > for example, the results for (a,b,c,d) would be marked as for index =0, > (b,c,d) would be index=1 > > On Sun, Mar 13, 2016 at 9:52 PM, James Keener <mailto:j...@jimkeener.com>> wrote: > &

Re: [GENERAL] retrieve grouping sets/rollup rows

2016-03-13 Thread James Keener
Do you want to know if a row is from the (a,b) or (c,d) group? All rows will contain (a,b,c,d) but (a,b) will be NULL for the (c,d) grouping sets, and vice-versa. Jim On 03/13/2016 09:45 PM, Tom Smith wrote: > Hello: > > With JDBC, how can I tell which row is for which grouping sets or rollup >

[GENERAL] INDEX ONLY scan with expression index

2016-03-07 Thread James Sewell
Hello, Would anyone be able to shed some light on why expression based indexes can't be used for an index only scan? I've found a few comments saying this is the case, and I've proven it is the case in reality - but I can't seem to find the why. Cheers, James Sewell,

Re: [GENERAL] PostgreSQL 9.5 and process REST calls enquiry

2016-02-12 Thread James Keener
> > > https://github.com/begriffs/postgrest also looks interesting! >> > > I thought the purpose of Spring/Spring Boot was to provide the REST > services in front of your choice of data store. Not sure how putting > another server in the stack is going to help things. I was simply responding to t

Re: [GENERAL] PostgreSQL 9.5 and process REST calls enquiry

2016-02-12 Thread James Keener
https://github.com/begriffs/postgrest also looks interesting! On Fri, Feb 12, 2016 at 10:24 AM, Adrian Klaver wrote: > On 02/12/2016 03:00 AM, Peter van Eck wrote: > >> >> >> Hi, We are looking into setting up a PostgreSQL environment for an >> application that inputs JSON through via http rest

Re: [GENERAL] WIP: CoC

2016-01-12 Thread James Keener
> > > https://modelviewculture.com/pieces/codes-of-conduct-when-being-excellent-is-not-enough > That post seems to discuss why a written CoC is needed (as opposed to an unwritten "act professional" one). I don't believe it applies to my comment.

Re: [GENERAL] Code of Conduct: Is it time?

2016-01-12 Thread James Keener
This line has already been substantially changes. Can we keep discussion of the language of the WIP in the thread meant for it? This way people don't waste time discussing language which no longer exists. Jim On January 12, 2016 9:17:55 AM EST, Neil Tiffin wrote: > >> On Jan 12, 2016, at 7:50

Re: [GENERAL] WIP: CoC

2016-01-12 Thread James Keener
Wow. I mean actually wow. So many things. Just so many. You still haven't explained why core contributors need to be treated like special snowflakes. If someone acts inappropriately then they should be told so, regardless of status. Why should we protect anyone in the wrong? Moreover, your sc

Re: [GENERAL] WIP: CoC

2016-01-12 Thread James Keener
>> That has nothing to do with the Code of Conduct, though. >> The community accepting Tom saying "no" to Feature X is >> vastly different than the community not calling Tom out >> for being mean. >> The CoC is about the later situation and not the prior; >> and the community should call Tom out. (

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
>> That has nothing to do with the Code of Conduct, though. The >> community accepting Tom saying "no" to Feature X is vastly >> different than the community not calling Tom out for being mean. > >> The CoC is about the later situation and not the prior; and the >> community should call Tom out.

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
>> We value the opinions of members who have contributed most more than > we value the opinions of others. > >> A CoC is not the place to say some animals are more equal than others. A > core commiter calling someone the n- or b- words is just as bad as me, a > non commiter (if not worse!) > > Ye

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
Why must it be free of personal comments? "Tom, I like the way you handed this issue. Good work!" Is a personal comment. Why do we need lists? What specifically is wrong with "that focuses on the tech and not the person" version? Jim On January 11, 2016 6:04:03 PM EST, "Joshua D. Drake" wrot

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
> We value the opinions of members who have contributed most more than we value > the opinions of others. A CoC is not the place to say some animals are more equal than others. A core commiter calling someone the n- or b- words is just as bad as me, a non commiter (if not worse!) > While we do

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
> A safe, respectful, productive and collaborative environment is one that focuses on the technical merit of ideas and solutions rather than on the person behind them. I still prefer this wording as there is no need for us to list the ways in which someone can personally be attacked. Should the l

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
On January 11, 2016 5:44:56 PM EST, "Joshua D. Drake" wrote: >On 01/11/2016 02:30 PM, James Keener wrote: >> (Sorry for the dup post. I felt having a clean thread without having >to >> cross-reference was worth the minor faux pas.) >> >>>3. A safe, respectf

Re: [GENERAL] WIP: CoC

2016-01-11 Thread James Keener
(Sorry for the dup post. I felt having a clean thread without having to cross-reference was worth the minor faux pas.) > 3. A safe, respectful, productive and collaborative environment is free of comments related to gender, sexual orientation, disability, physical appearance, body size or race. w

Re: [GENERAL] Code of Conduct: Is it time? (WIP CoC)

2016-01-11 Thread James Keener
> 3. A safe, respectful, productive and collaborative environment is free of comments related to gender, sexual orientation, disability, physical appearance, body size or race. why not > 3. A safe, respectful, productive and collaborative environment is free of ad hominem. (Tip: Ask your self "Wo

[GENERAL] Bug Tracker

2016-01-11 Thread James Keener
There was a side thread in the CoC thread about expanding the dev community and making it easier for new devs to get involved. I would think that a bug tracker, especially one where bugs can be labeled as "Newbie Friendly" could go a long way towards that goal. Additionally, a proper bug tracker w

Re: [GENERAL] Fwd: dblink_connect fails

2016-01-10 Thread James Sewell
Oops forgot to reply back to this one in the Christmas shutdown. It turned out in this (new) install on Windows Postgres was running as the Network Service user (??). This was causing the issue, changed to Postgres and I was all good. Cheers, James Sewell, Solutions Architect

Re: [GENERAL] Charging for PostgreSQL

2016-01-06 Thread James Keener
How does one "start a new thread"? I wasn't aware that changing the subject wouldn't be enough. I tried :/ Jim On January 6, 2016 12:17:54 PM EST, "Stéphane Schildknecht" wrote: >On 06/01/2016 16:54, James Keener wrote: >> As Melvin mentioned, this belo

Re: [GENERAL] Code of Conduct: Is it time?

2016-01-06 Thread James Keener
> No, CoC by itself doesn't grow the community. That doesn't mean we > shouldn't have one. I'd agree with that. Thinking back over my previous points, it does make sense to have one, if only to deal with people who represent the community in some way, i.e. have some kind of commit or marketing acce

Re: [GENERAL] Code of Conduct: Is it time?

2016-01-06 Thread James Keener
> The coc sounds like a Washington politics play, but as long as the best > still engage > in this forum, I could care less. The list serves its purpose without > overhead...a rare > resource in today's flood of incoherent technical chatter. Beyond "Hey! Look at us! We're telling people to play ni

[GENERAL] Charging for PostgreSQL

2016-01-06 Thread James Keener
n the first place, then I'm not sure this is an argument worth continuing. Jim > > > > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of James Keener > Sent: 06 January 2016 15:04 > To: Fa

Re: [GENERAL] Code of Conduct: Is it time?

2016-01-06 Thread James Keener
> My only aim is further progress of postgresql. Charging for it would do exactly that. Most people would simply switch to MySQL (or Maria) or stop upgrading/upgrade to a fork. > As per Sun Microsystem’s case charging zero dollars (for Java and mysql) > means there is zero income. Why do you thin

Re: [GENERAL] Code of Conduct: Is it time?

2016-01-06 Thread James Keener
What are you talking about? What business structure? Commercial offerings can and will continue to exist in terms of custom features or consulting. Firstly, it ceases to be a community version when there is a charge. Secondly, it would damage our community by shrinking the size to effectively no

[GENERAL] dblink connect per socket / specify cluster name

2015-12-20 Thread james garner
Dear list, i'm running PgSQL 9.3 on Debian installed from the Debian packets. I'm using dblink to access a different database. When im trying to connect to the database by socket via dblink_exec('dbname=test host=/var/run/postgresql' .. everything works nicely if there's just one db-cluster named

[GENERAL] Fwd: dblink_connect fails

2015-12-16 Thread James Sewell
Oops left off the list. -- Forwarded message -- From: *James Sewell* Date: Thursday, 17 December 2015 Subject: dblink_connect fails To: Joe Conway On Thu, Dec 17, 2015 at 12:11 PM, Joe Conway > wrote: > On 12/16/2015 04:53 PM, James Sewell wrote: > >

Re: [GENERAL] dblink_connect fails

2015-12-16 Thread James Sewell
No it is not. Just in case I tried setting it to 'postgres', logged in without -U (doesn't work without PGUSER set) and tried the operation again. Same result. Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect __ Level

[GENERAL] dblink_connect fails

2015-12-15 Thread James Sewell
t for being on 9.4.0) which this works on. Cheers, James Sewell, Solutions Architect __ Level 2, 50 Queen St, Melbourne VIC 3000 *P *(+61) 3 8370 8000 *W* www.lisasoft.com *F *(+61) 3 8370 8099 -- -- The contents of this ema

Re: [GENERAL]

2015-11-13 Thread James Keener
Who were you logged I to psql as? Does the dump switch users? On November 13, 2015 12:38:19 AM EST, Alex Luya wrote: >Hello, > I created a new database by > > create database icare; > > then quit off psql and run: > >pg_restore --clean --create --exit-on-error --dbname

Re: [GENERAL] Multiple insert

2015-09-19 Thread James Keener
You are inserting ((),()). It should be (),(). Skip the outer set of parentheses. On September 19, 2015 2:31:53 PM EDT, "FarjadFarid(ChkNet)" wrote: >Hi, > > > >I am getting errors trying to insert multiple records in single >statement in >table like this > > > >CREATE TABLE "Lookup"."CNEnum

Re: [GENERAL] Anyone interested in a Pittsburgh-area Postgres users'

2015-09-08 Thread James Keener
Is there a user group in Pittsburgh? This email was the first that showed up in a Google Search. Jim On 2004-05-02 05:43:26, Tom Lane wrote: > I've gotten a couple of inquiries lately about a Postgres users' group > in my home town of Pittsburgh PA. There is not one (unless it's very > well ca

Re: [GENERAL] SPI_execute error handling

2015-09-07 Thread James Harper
> Hi > > > When I need to solve similar situation, I take a code from plpgsql. > look on function exec_stmt_block. Similar code is in plpgsql_check > https://github.com/okbob/plpgsql_check/blob/master/plpgsql_check.c > Thanks. Got it sorted! James -- Sent via pgsql

[GENERAL] SPI_execute error handling

2015-09-07 Thread James Harper
ds handler" And control is never returned to my worker, as expected. How can I get control returned back to my worker so that I can give the client program a sensible error? I already create a transaction like StartTransactionCommand(), but then maybe that isn't the subtransation that

[GENERAL] Invalid memory alloc request size

2015-08-24 Thread Mike James
1 with 102 table(s) from provider 1 2015-08-24 06:50:33 UTC ERROR remoteWorkerThread_1_1: error at end of COPY IN: ERROR: invalid memory alloc request size 1970234207 CONTEXT: COPY sl_log_1, line 97033: [image: Clutch Holdings, LLC] <http://www.clutch.com> Mike James | Manager of Infra

Re: [GENERAL] How to test SSL cert from CA?

2015-07-11 Thread James Cloos
;s protocol, but it should be straight forward to do so.-JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- 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 test SSL cert from CA?

2015-07-11 Thread James Cloos
trusts the issuer's root? Some require explicit configurastion of that. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] WAL log archival on standby

2015-06-18 Thread James Sewell
. This would result in a doubling of my network traffic. Ideally I'd prefer to conserve this bandwidth and write the files to a local archive on any active standby. Cheers, James Sewell, Solutions Architect __ Level 2, 50 Queen St, Melbourne VIC 300

Re: [GENERAL] localtime ?

2015-06-15 Thread James Cloos
es? It is 9.3 vs 9.4 on the same box. OE> You can reconfigure the timezone for the machine: OE> sudo dpkg-reconfigure tzdata And /etc/localtime is a copy of /usr/share/zoneinfo/Zulu. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgsql

Re: [GENERAL] localtime ?

2015-06-15 Thread James Cloos
>>>>> "AK" == Adrian Klaver writes: AK> So from the command line on the non-UTC machine what does the below show: AK> ~>date It is the same machine, just the old 9.3 cluster vs the new 9.4 cluster. date returns: Mon Jun 15 19:37:14 UTC 2015 -Jim

Re: [GENERAL] localtime ?

2015-06-15 Thread James Cloos
files. As I wrote the diff between the not working /etc/postgresql/9.3/ snd the working /etc/postgresql/9.4/ is only things like 9.3 vs 9.4 in path names, the port number and the addition in 9.4 of dynamic_shared_memory_type = mmap. Whatever caused this is not in the config files. -JimC -- James

Re: [GENERAL] localtime ?

2015-06-15 Thread James Cloos
sourceline | 508 The 9.3 vs 9.4 in sourcefile is the only difference between the two clusters on that box. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.post

Re: [GENERAL] localtime ?

2015-06-11 Thread James Cloos
directories doesn't show any relevant differences. Just directory names and the port number. I'll leave the old cluster stopped but around for a while in case there are any other queries which might explain the differences. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 --

[GENERAL] localtime ?

2015-06-11 Thread James Cloos
# share/timezonesets/. ` So how do I convince it always to use utc? (I did that test w/ ~/.psqlrc moved out of the way, but it does nothing related to tz.) Thanks. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgs

Re: [GENERAL] Streaming replication and an archivelog

2015-05-08 Thread James Sewell
by stopping them ever knowing about history files. Can anyone see any problems with this approach? Cheers, James Sewell, PostgreSQL Team Lead / Solutions Architect __ Level 2, 50 Queen St, Melbourne VIC 3000 *P *(+61) 3 8370 8000 *W* www.lisasoft.com

Re: [GENERAL] Streaming replication and an archivelog

2015-05-07 Thread James Sewell
the server forked off from that timeline at B/BE60. 2015-05-08 16:23:11 AEST @ ( 0 0)LOG: startup process (PID 21893) exited with exit code 1 2015-05-08 16:23:11 AEST @ ( 0 0)LOG: aborting startup due to startup process failure Cheers, James Sewell, PostgreSQL Team Lead / Solutions Ar

[GENERAL] Streaming replication and an archivelog

2015-05-07 Thread James Sewell
switches, not archive timeline switches. Obviously if I am not a streaming replica I need to follow archive timeline switches so I don't break PIT recovery. Possible? James Sewell, PostgreSQL Team Lead / Solutions Architect __ Level 2, 50 Queen St,

Re: [GENERAL] now() vs 'epoch'::timestamp

2015-04-02 Thread James Cloos
o, I guess that is another nail in reltime's coffin. now() - to_timestamp(1427999266) worked correctly, but that is not unexpected given to_timestamp's definition. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgsql

Re: [GENERAL] now() vs 'epoch'::timestamp

2015-04-02 Thread James Cloos
>>>>> "DGJ" == David G Johnston writes: DGJ> ​What timezone is your server set to - and/or the client requesting the DGJ> calculation? Everything is in UTC. -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (p

Re: [GENERAL] now() vs 'epoch'::timestamp

2015-04-02 Thread James Cloos
SC> side of the calculation. It wasn't the microsecond difference I asked about, it was the 6 hour difference. The original, ancient code I used needed to return integer seconds. And it always gave answers consistant with date +%s. What I haven't determined is why conver

Re: [GENERAL] now() vs 'epoch'::timestamp

2015-04-01 Thread James Cloos
Thanks. Back when I first needed it (years ago), that long line was the only recomendation I could find. SF> The only thing I'd say about this is that you *really* want to use SF> timestamptz in PG for storing timestamps. I normally do, but this table hasn't changed in ye

[GENERAL] now() vs 'epoch'::timestamp

2015-04-01 Thread James Cloos
all have localtime == UTC. Am I missing something obvious? Also, is there any way to get the equiv of date +%s%N as a numeric or a double precision? -JimC -- James Cloos OpenPGP: 0x997A9F17ED7DAEA6 -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To

Re: [GENERAL] How do I calculate the sum of a field filtered by multiple windows defined by another field?

2015-03-15 Thread Robert James
Version 9.2.4 On 3/15/15, David G. Johnston wrote: > On Sunday, March 15, 2015, Robert James wrote: > >> How do I calculate the sum of a field filtered by multiple windows >> defined by another field? >> >> I have table event with fields event_date, num_events

[GENERAL] Preserving formatting and comments in a VIEW definition

2015-03-15 Thread Robert James
When I save a VIEW, Postgres seems to convert it to a different format, functionally equivalent but unrecognizable (whitespace, comments, adds lots of casts, etc.) Is there any simple way to preserve my original code? -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

[GENERAL] How do I calculate the sum of a field filtered by multiple windows defined by another field?

2015-03-15 Thread Robert James
How do I calculate the sum of a field filtered by multiple windows defined by another field? I have table event with fields event_date, num_events, site_id. I can easily use aggregate SQL to do SELECT SUM(num_events) GROUP BY site_id. But I also have another table site with fields site_id, target

  1   2   3   4   5   6   7   >