RE: Circle and box intersect

2018-03-16 Thread Martin Moore
Am 16.03.2018 um 11:00 schrieb Martin Moore: > PG10 > > Is there an operator to determine if a box and circle intersect? > I can only see box && box and can use centre+rad and distance to > calculate circle:circle. > > Thanks. > > please don't hijack other mai

Circle and box intersect

2018-03-16 Thread Martin Moore
PG10 Is there an operator to determine if a box and circle intersect? I can only see box && box and can use centre+rad and distance to calculate circle:circle. Thanks.

Re: What is wrong with my pgadmin?

2018-03-05 Thread Martin Moore
Using pgAdmin 4 2.0 on pg 9.6 and 10 I get div/0 error. On 05/03/2018, 14:22, "Adrian Klaver" wrote: On 03/05/2018 06:05 AM, Łukasz Jarych wrote: > Hi Guys, > > what is wrong with my pgAdmin? > > I am creating wrong query: > > select 1/0 but still this is ex

Re: Enforce primary key on every table during dev?

2018-03-01 Thread Martin Moore
On 03/01/2018 11:47 AM, Daevor The Devoted wrote: >I can't stand synthetic keys. By their very nature, they're so purposelessly >arbitrary, and allow you to insert garbage into the >table. How does not having a ‘real’ PK allow you to insert garbage and a ‘real’ one prevent garbage? If the

Re: Not sure if I should CREATE INDEX for text columns on which I plan to filter later

2018-02-21 Thread Martin Moore
>However, Martin's other comment about only using a single index is > incorrect. > Postgres can use multiple indexes per query, so it's often good practace to > put indexes on every column that might ever be used in a WHERE clause. > -- > Bill Moran That's ve

Re: Not sure if I should CREATE INDEX for text columns on which I plan to filter later

2018-02-21 Thread Martin Moore
Hi Martin - On Wed, Feb 21, 2018 at 1:26 PM, Martin Moore wrote: I’m no expert but I’d think it unlikely an index would be considered for a table with only 100 rows in. Also I’m pretty sure only one index per table is used, so you’d want to put state1 and state2 in one index. I hope to

Re: Not sure if I should CREATE INDEX for text columns on which I plan to filter later

2018-02-21 Thread Martin Moore
I’m no expert but I’d think it unlikely an index would be considered for a table with only 100 rows in. Also I’m pretty sure only one index per table is used, so you’d want to put state1 and state2 in one index. You may wish to consider normalising too – so any field with a 1 or 2 at the end

Re: postgres for production

2018-01-31 Thread Martin Moore
How much data do you have? That’s a fundamental thing to know. Martin. From: Azimuddin Mohammed Date: Wednesday, 31 January 2018 at 16:24 To: , Subject: postgres for production Hello, I have a question for postgres hardware requirement for production installation. My org want to

Changing locale/charset

2018-01-22 Thread Martin Moore
I created a 10.1 cluster on Debian using UTF8. I’d like to convert it to LATIN1, but am having various issues. So, it’s probably easiest to start again (I have a dump of the DB). To ensure I get it right, what is the correct way to create a cluster with LATIN1 encoding, how to remove the exist

Re: Slow system due to ReorderBufferGetTupleBuf?

2018-01-02 Thread Martin Moore
On 02/01/2018, 12:09, "Martin Moore" wrote: On 01/01/2018, 17:45, "Peter Geoghegan" wrote: On Mon, Jan 1, 2018 at 8:56 AM, Martin Moore wrote: > Can someone shed some light on this and advise how to prevent it reoccurring?

Re: Slow system due to ReorderBufferGetTupleBuf?

2018-01-02 Thread Martin Moore
On 01/01/2018, 17:45, "Peter Geoghegan" wrote: On Mon, Jan 1, 2018 at 8:56 AM, Martin Moore wrote: > Can someone shed some light on this and advise how to prevent it reoccurring? You're using v10, which has these two commits: https://git.postgr

Slow system due to ReorderBufferGetTupleBuf?

2018-01-01 Thread Martin Moore
Postgres v10 on Debian stretch I’m suffering from an occasionally very slow system. A few weeks ago someone mentioned using perf. I’ve installed this and caught the system during a slow period. It shows the following as the top cpu users: 9.09% postgres [.] ReorderBufferGe

Re: Find duplicates in a column then print Information to a file

2017-12-31 Thread Martin Moore
From: Sherman Willden Date: Sunday, 31 December 2017 at 18:19 To: Subject: Find duplicates in a column then print Information to a file Development Platform: Ubuntu 17.10 mainly command line work Tools: perl 5.26 and postgresql 9.6 Goal: Display duplicate aria titles on screen and to a l

Re: Replication causing publisher node to use excessive cpu over time

2017-12-04 Thread Martin Moore
OK, have installed perf and will report back when the problem gets noticeable. Martin. On 04/12/2017, 12:40, "Michael Paquier" wrote: On Mon, Dec 4, 2017 at 9:03 PM, Martin Moore wrote: > After a few days, it’s noticeable that the Postgres on the publisher node is con

Replication causing publisher node to use excessive cpu over time

2017-12-04 Thread Martin Moore
% today) and having a big impact on the system performance even when doing very little. Logging on to the subscriber and removing the subscription sees this value drop to an expect small value. I can’t see that this can be anything but a bug, but happy for any thoughts :) Martin Moore