Re: Speeding up INSERTs and UPDATEs to partitioned tables

2018-11-12 Thread David Rowley
On 9 November 2018 at 19:18, Amit Langote wrote: > I have a comment regarding how you chose to make > PartitionTupleRouting private. > > Using the v14_to_v15 diff, I could quickly see that there are many diffs > changing PartitionTupleRouting to struct PartitionTupleRouting, but they > would be

Re: move PartitionBoundInfo creation code

2018-11-12 Thread Amit Langote
On 2018/11/13 11:34, Michael Paquier wrote: > Attached is an updated patch. Perhaps you are spotting something else? Looks good to me. Thanks, Amit

Re: Support custom socket directory in pg_upgrade

2018-11-12 Thread Peter Eisentraut
On 12/11/2018 20:00, Tom Lane wrote: > Also, even if we had an arguably-better idea, I suspect that there would > always be cases where it didn't work. For example, one idea is to make > a temporary directory under the installation's normal socket directory > (thus, /tmp/pg/ or some such).

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread Tom Lane
Andres Freund writes: > On 2018-11-13 00:01:49 +0100, David Fetter wrote: >> So if this got added to a lot of compilers, that might suffice. > No, unless those compiler versions will automatically be available in > older distros. Which they won't. Yeah. I think putting this in core is a long

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread Pavel Stehule
út 13. 11. 2018 v 0:55 odesílatel Tom Lane napsal: > Andres Freund writes: > > On 2018-11-13 00:01:49 +0100, David Fetter wrote: > >> So if this got added to a lot of compilers, that might suffice. > > > No, unless those compiler versions will automatically be available in > > older distros.

Re: move PartitionBoundInfo creation code

2018-11-12 Thread Michael Paquier
On Tue, Nov 13, 2018 at 10:34:50AM +0900, Amit Langote wrote: > Hmm, Assert or elog is your call, but I'd learned that we prefer elog when > checking a value read from the disk? Let's keep elog() then, which is consistent with the previous code. If there is any meaning in switching to an

Re: doc fix for pg_stat_activity.backend_type

2018-11-12 Thread Amit Kapila
On Tue, Nov 13, 2018 at 5:38 AM Michael Paquier wrote: > > On Mon, Nov 12, 2018 at 09:42:45PM +0700, John Naylor wrote: > > Looks like it. A quick search revealed "parallel worker" and "logical > > replication worker". src/test/modules/ also show "test_shm_mq" and > > "worker_spi", but it seems

Re: Removal of unnecessary CommandCounterIncrement() when doing ON COMMIT DELETE ROWS

2018-11-12 Thread Michael Paquier
On Mon, Nov 12, 2018 at 01:19:31PM -0300, Alvaro Herrera wrote: > On 2018-Nov-09, Michael Paquier wrote: >> When doing a set of ON COMMIT DELETE ROWS actions for relations, there >> is a CCI happening after each truncation: > > Right, but note that this is not a loop so it's only one CCI, not one

Re: Copy data to DSA area

2018-11-12 Thread Thomas Munro
On Tue, Nov 13, 2018 at 9:45 AM Robert Haas wrote: > On Thu, Nov 8, 2018 at 9:05 PM Thomas Munro > wrote: > > * I had some ideas about some kind of "allocation rollback" interface: > > you begin an "allocation transaction", allocate a bunch of stuff > > (perhaps indirectly, by calling some API

Re: Possible buffer overrun in src/backend/libpq/hba.c gethba_options()

2018-11-12 Thread Thomas Munro
On Tue, Nov 13, 2018 at 3:42 PM Thomas Munro wrote: > On Tue, Nov 13, 2018 at 3:02 PM Julian Hsiao wrote: > > During a routine Coverity scan of our internal PostgreSQL fork, it > > issued a buffer overrun warning for src/backend/libpq/hba.c, > > gethba_options()[0]: > > > > MAIN_ISSUE

Re: move PartitionBoundInfo creation code

2018-11-12 Thread Amit Langote
On 2018/11/13 12:40, Amit Langote wrote: > On 2018/11/13 11:34, Michael Paquier wrote: >> Attached is an updated patch. Perhaps you are spotting something else? > > Looks good to me. Marked the CF entry as Ready for Committer. Thanks, Amit

Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation

2018-11-12 Thread Tom Lane
=?UTF-8?Q?J=c3=bcrgen_Strobel?= writes: > On 2018-11-12 17:33, Tom Lane wrote: >> I'm not entirely convinced that I buy that argument, especially not in >> a case like this where it introduces logical inconsistencies where there >> otherwise wouldn't be any. > I think I missed something, what

RE: [Proposal] Add accumulated statistics for wait event

2018-11-12 Thread Yotsunaga, Naoki
On Sun, Oct 28, 2018 at 6:39 PM, legrand legrand wrote: Hi, Thanks for comments. I had overlooked the reply from you. >You are right, sampling has to be "tuned" regarding the event(s) you want to >catch. I see. For tuning, you need to know the length of processing you want to sample? > May

Re: Resetting PGPROC atomics in ProcessInit()

2018-11-12 Thread Amit Kapila
On Fri, Nov 9, 2018 at 10:28 AM Amit Kapila wrote: > > On Thu, Nov 8, 2018 at 4:38 PM Amit Kapila wrote: > > On Sun, Nov 4, 2018 at 6:30 AM Robert Haas wrote: > > > On Sat, Oct 27, 2018 at 6:41 AM Andres Freund wrote: > > Okay, changed the code as per Andres's and your suggestion. Do you > >

Re: New function pg_stat_statements_reset_query() to reset statistics of a specific query

2018-11-12 Thread Haribabu Kommi
On Mon, Nov 12, 2018 at 6:34 PM Amit Kapila wrote: > On Mon, Nov 12, 2018 at 10:55 AM Haribabu Kommi > wrote: > > > > I can revert it back to void, > > > > +1, as we don't see any good reason to break backward compatibility. > Thanks for the review. Attached the updated patch with return type

Re: [Bug Fix]ECPG: cancellation of significant digits on ECPG

2018-11-12 Thread Tom Lane
"Higuchi, Daisuke" writes: > From: Dmitry Dolgov [mailto:9erthali...@gmail.com] >> Thanks for the patches. Unfortunately, judging from the cfbot.cputube.org >> they >> can't be applied anymore to the current master, could you please rebase them? > Thank you for checking! > I rebased patches on

Re: Support custom socket directory in pg_upgrade

2018-11-12 Thread Tom Lane
Peter Eisentraut writes: > On 12/11/2018 20:00, Tom Lane wrote: >> Also, even if we had an arguably-better idea, I suspect that there would >> always be cases where it didn't work. For example, one idea is to make >> a temporary directory under the installation's normal socket directory >>

Re: move PartitionBoundInfo creation code

2018-11-12 Thread Amit Langote
Hi, On 2018/11/12 22:55, Michael Paquier wrote: > On Thu, Nov 08, 2018 at 03:11:35PM +0900, Amit Langote wrote: >> And here is the new version. The break down into smaller local >> functions for different partitioning methods is in patch 0002. > > Okay, here we go. Thank you for reviewing. >

Possible buffer overrun in src/backend/libpq/hba.c gethba_options()

2018-11-12 Thread Julian Hsiao
Hi, During a routine Coverity scan of our internal PostgreSQL fork, it issued a buffer overrun warning for src/backend/libpq/hba.c, gethba_options()[0]: MAIN_ISSUE EventDescription: Overrunning array "options" of 12 8-byte elements at element index 12 (byte offset 96) using index "noptions++"

Re: Pull up sublink of type 'NOT NOT (expr)'

2018-11-12 Thread Tom Lane
Richard Guo writes: > Currently for quals in the form of "NOT NOT (SubLink)", this SubLink would > not be considered when pulling up sublinks. Yup. > Should we give it a chance, like the attached does? What is the argument that this occurs often enough to be worth expending extra cycles and

RE: [Proposal] Add accumulated statistics

2018-11-12 Thread Yotsunaga, Naoki
On Mon, Nov 5, 2018 at 4:26 PM, Naoki Yotsunaga wrote: >>2) it consumes system resources >While the system is running, you are always sampling system information, do >not you? Like Oracle ASH. I don’t understand well how sampling is used. In which scene do you use the sampling? Or is it both

Re: Restore CurrentUserId only if 'prevUser' is valid when abort transaction

2018-11-12 Thread Michael Paquier
On Mon, Nov 12, 2018 at 08:17:29PM -0500, Tom Lane wrote: > I don't like this too much, because it does not scale: there can be > only one action that can rely on executing "just before we switch to > TRANS_INPROGRESS". Okay. > I think the real bug here is that a bunch of potentially-failable >

Re: doc fix for pg_stat_activity.backend_type

2018-11-12 Thread Michael Paquier
On Mon, Nov 12, 2018 at 09:42:45PM +0700, John Naylor wrote: > Looks like it. A quick search revealed "parallel worker" and "logical > replication worker". src/test/modules/ also show "test_shm_mq" and > "worker_spi", but it seems those don't need to be publicly documented. > If that sounds right

Re: Restore CurrentUserId only if 'prevUser' is valid when abort transaction

2018-11-12 Thread Tom Lane
Michael Paquier writes: > So, I have spent a couple of hours today looking a bit more at the > problem, and I have hacked the attached patch that I am pretty happy > with: I don't like this too much, because it does not scale: there can be only one action that can rely on executing "just before

Re: Possible buffer overrun in src/backend/libpq/hba.c gethba_options()

2018-11-12 Thread Thomas Munro
On Tue, Nov 13, 2018 at 3:02 PM Julian Hsiao wrote: > During a routine Coverity scan of our internal PostgreSQL fork, it > issued a buffer overrun warning for src/backend/libpq/hba.c, > gethba_options()[0]: > > MAIN_ISSUE EventDescription: Overrunning array "options" of 12 8-byte > elements at

Re: PostgreSQL vs SQL/XML Standards

2018-11-12 Thread Pavel Stehule
po 12. 11. 2018 v 6:58 odesílatel Markus Winand napsal: > > On 2018-11-9, at 05:07 , Pavel Stehule wrote: > > > > čt 8. 11. 2018 v 15:18 odesílatel Markus Winand > napsal: > >> >> > On 2018-11-6, at 15:23 , Pavel Stehule wrote: >> > >> > >> > >> > po 29. 10. 2018 v 11:45 odesílatel Pavel

Re: BUG #15449: file_fdw using program cause exit code error when using LIMIT

2018-11-12 Thread Kyotaro HORIGUCHI
At Fri, 09 Nov 2018 18:27:09 +0900, Etsuro Fujita wrote in <5be552ed.4040...@lab.ntt.co.jp> > > Ok, I can live with that with no problem. > > OK ... > > I think Thomas just saying that reading more lines can develop > > problems. According to the current discussion, we should error > > out if

Re: BUG #15449: file_fdw using program cause exit code error when using LIMIT

2018-11-12 Thread Kyotaro HORIGUCHI
At Fri, 9 Nov 2018 20:32:54 +1300, Thomas Munro wrote in > On Fri, Nov 9, 2018 at 6:39 PM Kyotaro HORIGUCHI > wrote: > > Mmm..I didn't get an error at hand on both CentOS7 and High Sierra. > > > > | $ perl -e 'for (my $i=0; $i< 100; $i++) { print "$i\n"; }' | head -5 > > ... > > | 4 > > |

Re: DSM segment handle generation in background workers

2018-11-12 Thread Thomas Munro
On Mon, Nov 12, 2018 at 9:34 PM Noah Misch wrote: > On Sat, Oct 13, 2018 at 11:45:17PM +1300, Thomas Munro wrote: > > + /* Set a different seed for random() in every backend. */ > > + srandom((unsigned int) MyProcPid ^ (unsigned int) MyStartTimestamp); > > > - TimestampDifference(0,

Re: doc fix for pg_stat_activity.backend_type

2018-11-12 Thread John Naylor
On 11/13/18, Amit Kapila wrote: > On Tue, Nov 13, 2018 at 5:38 AM Michael Paquier > wrote: >> >> On Mon, Nov 12, 2018 at 09:42:45PM +0700, John Naylor wrote: >> > Looks like it. A quick search revealed "parallel worker" and "logical >> > replication worker". src/test/modules/ also show

Re: Libpq support to connect to standby server as priority

2018-11-12 Thread Haribabu Kommi
On Tue, Nov 13, 2018 at 7:26 AM Laurenz Albe wrote: > Tom Lane wrote: > > Laurenz Albe writes: > > > Haribabu Kommi wrote: > > > > Added comments along the lines that you mentioned. And also try > > > > to update some more comments. > > > Looks ok to me, I'll mark it as "ready for committer". >

Re: libpq debug log

2018-11-12 Thread Haribabu Kommi
On Tue, Oct 30, 2018 at 8:38 PM Iwata, Aya wrote: > Hi, > > I create a first libpq trace log patch. > > In this patch, > - All message that PQtrace() gets are output to the libpq trace log file > (I maybe select more effective message in the future patch) > - Trace log output style is changed

Re: PostgreSQL Limits and lack of documentation about them.

2018-11-12 Thread John Naylor
On 11/8/18, David Rowley wrote: > On 8 November 2018 at 22:46, Peter Eisentraut > wrote: >> Could you adjust this to use fewer capital letters, unless they start >> sentences or similar? > > Yeah. Changed in the attached. Looks good to me. Since there have been no new suggestions for a few

Re: Small run-time pruning doc fix

2018-11-12 Thread Peter Eisentraut
On 04/11/2018 06:23, David Rowley wrote: > Thanks for looking at this. > > On 2 November 2018 at 20:30, Peter Eisentraut > wrote: >> >> - Execution-time partition pruning currently occurs for the >> + Execution-time partition pruning currently only occurs for the >> Append

Re: Continue work on changes to recovery.conf API

2018-11-12 Thread Peter Eisentraut
On 30/10/2018 14:30, Sergei Kornilov wrote: > I attached new version of this patch due merge conflict with pg_promote > function. This patch looks pretty good to me functionality-wise. There are some code details to work through, listed below. In this review, I'm skipping over your

Re: Index Skip Scan

2018-11-12 Thread Sergei Kornilov
Hello Last published patch index-skip-fallback-v2 applied and builds cleanly. I found reproducible crash due assert failure: FailedAssertion("!(numCols > 0)", File: "pathnode.c", Line: 2795) > create table tablename (i int primary key); > select distinct i from tablename where i = 1; Query is

Re: BUG #15449: file_fdw using program cause exit code error when using LIMIT

2018-11-12 Thread Etsuro Fujita
(2018/11/12 18:52), Kyotaro HORIGUCHI wrote: At Fri, 09 Nov 2018 18:27:09 +0900, Etsuro Fujita wrote in<5be552ed.4040...@lab.ntt.co.jp> Ok, I can live with that with no problem. OK ... I think Thomas just saying that reading more lines can develop problems. According to the current

Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation

2018-11-12 Thread Jürgen Strobel
On 2018-11-09 23:33, Tom Lane wrote: > Alvaro Herrera writes: >> On 2018-Nov-09, Jürgen Strobel wrote: >>> Regarding your example, what I expected is that *both* inserts would >>> consistently result in a tuple of (1, 42) since p should route the >>> insert to p1 and use p1's defaults. The

Re: move PartitionBoundInfo creation code

2018-11-12 Thread Michael Paquier
On Thu, Nov 08, 2018 at 03:11:35PM +0900, Amit Langote wrote: > And here is the new version. The break down into smaller local > functions for different partitioning methods is in patch 0002. Okay, here we go. I have spent a couple of hours on this patch, checking the consistency of the new

Re: Uninterruptible long planning of a query with too many WHERE clauses

2018-11-12 Thread Alexander Kuzmenkov
El 11/11/18 a las 07:38, Tom Lane escribió: I think you have the right basic idea, but we don't have to completely lobotomize the bitmap-and search logic in order to cope with this. This code is only trying to figure out which paths are potentially redundant, so for a path with too many quals,

Re: Index Skip Scan

2018-11-12 Thread Dmitry Dolgov
> On Mon, 12 Nov 2018 at 13:29, Sergei Kornilov wrote: > > I found reproducible crash due assert failure: FailedAssertion("!(numCols > > 0)", File: "pathnode.c", Line: 2795) > > create table tablename (i int primary key); > > select distinct i from tablename where i = 1; > Query is obviously

Re: doc fix for pg_stat_activity.backend_type

2018-11-12 Thread Amit Kapila
On Mon, Nov 12, 2018 at 1:20 PM John Naylor wrote: > > Hi all, > > Commit fc70a4b0df3 added backend_type to pg_stat_activity, but the > documentation omitted "logical replication launcher". Patch attached. > Isn't this the fallout of commit 5373bc2a08 which has added background worker types? If

Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation

2018-11-12 Thread Alvaro Herrera
On 2018-Nov-12, Jürgen Strobel wrote: > With all due respect I suspect your view of implementation issues biases > your judgement here. For me the partition's default handling was > completely unexpected, especially with the documentation silent about > default-applying behavior, and inconsistent

Re: Uninterruptible long planning of a query with too many WHERE clauses

2018-11-12 Thread Tom Lane
Alexander Kuzmenkov writes: > El 11/11/18 a las 07:38, Tom Lane escribió: >> I think you have the right basic idea, but we don't have to completely >> lobotomize the bitmap-and search logic in order to cope with this. >> This code is only trying to figure out which paths are potentially >>

Re: doc fix for pg_stat_activity.backend_type

2018-11-12 Thread John Naylor
On 11/12/18, Amit Kapila wrote: > On Mon, Nov 12, 2018 at 1:20 PM John Naylor wrote: >> >> Hi all, >> >> Commit fc70a4b0df3 added backend_type to pg_stat_activity, but the >> documentation omitted "logical replication launcher". Patch attached. >> > > Isn't this the fallout of commit 5373bc2a08

Re: Removal of unnecessary CommandCounterIncrement() when doing ON COMMIT DELETE ROWS

2018-11-12 Thread Alvaro Herrera
On 2018-Nov-09, Michael Paquier wrote: > Hi all, > > When doing a set of ON COMMIT DELETE ROWS actions for relations, there > is a CCI happening after each truncation: Right, but note that this is not a loop so it's only one CCI, not one per relation. (This doesn't seem a big deal either way,

Re: Changes to error handling for background worker initialization?

2018-11-12 Thread Jeremy Finzel
On Mon, Oct 22, 2018 at 9:36 AM Jeremy Finzel wrote: > Hello - > > I have an extension that uses background workers. I pass a database oid > as an argument in order to launch the worker using function > BackgroundWorkerInitializeConnectionByOid. In one of my regression tests > that was

Re: DSM segment handle generation in background workers

2018-11-12 Thread Tom Lane
Thomas Munro writes: > On Mon, Nov 12, 2018 at 9:34 PM Noah Misch wrote: >> Compared to the old code, the new code requires more wall time to visit every >> possible seed value. New code xor's the PID bits into the fastest-changing >> timestamp bits, so only about twenty bits can vary within

Re: Support custom socket directory in pg_upgrade

2018-11-12 Thread Tom Lane
Daniel Gustafsson writes: >> On 7 Nov 2018, at 08:23, Peter Eisentraut >> wrote: >> Why not always create a temporary directory and put it there. Then we >> don't need an option. It's not like the current directory is a >> particularly good choice anyway. > I agree that cwd isn’t a terribly

PostgreSQL BuildFarm Client Release 9

2018-11-12 Thread Andrew Dunstan
Announcing Release 9 of the PostgreSQL Buildfarm client. Along with numerous fixes of minor bugs and a couple of not so minor bugs, this release has the following features: * new command line parameter --run-parallel for run_branches.pl runs all branches in parallel, possibly across

Re: Libpq support to connect to standby server as priority

2018-11-12 Thread Tom Lane
Laurenz Albe writes: > Haribabu Kommi wrote: >> Added comments along the lines that you mentioned. And also try >> to update some more comments. > Looks ok to me, I'll mark it as "ready for committer". I don't like this patch at all: the business with keeping two connections open seems

Race condition in WaitForBackgroundWorkerStartup

2018-11-12 Thread Jeremy Finzel
I believe I found a race condition in WaitForBackgroundWorkerStartup in the case where it encounters an ERROR during startup. I found that depending on the speed of the system, it will unreliably return either status BGWH_STOPPED or BGWH_STARTED. But I can reliably reproduce getting BGWH_STOPPED

Re: [HACKERS] [PATCH v2] Add and report the new "session_read_only" GUC pseudo-variable.

2018-11-12 Thread Elvis Pranskevichus
On Monday, November 12, 2018 1:08:37 PM EST Tom Lane wrote: > Looking through the thread, it seems like there's a pretty fundamental > design issue that hasn't been resolved, namely whether and how this > ought to interact with default_transaction_read_only. The patch as > it stands seems to be

Re: [HACKERS] Optional message to user when terminating/cancelling backend

2018-11-12 Thread Tom Lane
Daniel Gustafsson writes: > I’ve split the patch into two logical parts, the signalling functionality and > the userfacing terminate/cancel part. For extra clarity I’ve also included > the > full v19 patch, in case you prefer that instead when seeing the two. I'm a bit befuddled by this patch,

Re: NULL handling in exconfig deconstruction

2018-11-12 Thread Tom Lane
Daniel Gustafsson writes: > In extension_config_remove() we first ensure that pg_extension.extconfig > cannot > contain any NULL values in the array, ERRORing out if so. Later we however > ask > for NULL values back when deconstructing the array, throwing away the results > knowing there wont

Re: [HACKERS] [PATCH v2] Add and report the new "session_read_only" GUC pseudo-variable.

2018-11-12 Thread Tom Lane
Melanie Plageman writes: > On Mon, Sep 24, 2018 at 9:28 AM Elvis Pranskevichus > wrote: >> Sorry for the long silence on this. I'm attaching a rebased and >> cleaned-up patch with the earlier review issues addressed. I've checked >> all relevant tests and verified manually. > After taking a

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread Thomas Munro
On Fri, Jun 16, 2017 at 9:42 AM Thomas Munro wrote: > On Fri, Sep 25, 2015 at 5:06 PM, Pavel Stehule > wrote: > > 2015-09-25 0:25 GMT+02:00 Jim Nasby : > >> On 9/24/15 3:35 PM, Peter Geoghegan wrote: > >>> > >>> I would worry about the implicit casts you've added. They might cause > >>>

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread David Rowley
On 13 November 2018 at 10:39, Thomas Munro wrote: > ... and it has just been voted into the next revision of the C language: > > https://gustedt.wordpress.com/2018/11/12/c2x/ Nice. Maybe we can get DECFLOAT into core around PostgreSQL 32 or so :-) -- David Rowley

Re: Libpq support to connect to standby server as priority

2018-11-12 Thread Laurenz Albe
Tom Lane wrote: > Laurenz Albe writes: > > Haribabu Kommi wrote: > > > Added comments along the lines that you mentioned. And also try > > > to update some more comments. > > Looks ok to me, I'll mark it as "ready for committer". > > I don't like this patch at all: the business with keeping two

Re: Copy data to DSA area

2018-11-12 Thread Robert Haas
On Thu, Nov 8, 2018 at 9:05 PM Thomas Munro wrote: > * I had some ideas about some kind of "allocation rollback" interface: > you begin an "allocation transaction", allocate a bunch of stuff > (perhaps indirectly, by calling some API that makes query plans or > whatever and is totally unaware of

Re: libpq debug log

2018-11-12 Thread Jim Doty
Greetings, This is my first attempt at a patch review, so I will take a pass at the low hanging fruit. Initial Pass + Patch applies + Patch builds + Patch behaves as described in the thread I tried a few small things: When I set a relative path for `PGLOGDIR`, the files were

Re: Small run-time pruning doc fix

2018-11-12 Thread David Rowley
On 13 November 2018 at 02:46, Peter Eisentraut wrote: > Committed your change. Thanks. -- David Rowley http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services

Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation

2018-11-12 Thread Tom Lane
Alvaro Herrera writes: > One of the guiding principles that I think we should hold for > partitioning is that operating directly into the partition should be > seen as only an optimization compared to inserting into the parent table > -- thus it should not behave differently. Applying different

Re: libpq debug log

2018-11-12 Thread Jacob Champion
On Tue, Oct 30, 2018 at 2:39 AM Iwata, Aya wrote: > I create a first libpq trace log patch. Couple additional thoughts from a read-through of the patch: - PQtrace() and the new trace-logging machinery overlap in some places but not others -- and if both are set, PQtrace() will take precedence.

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread David Fetter
On Tue, Nov 13, 2018 at 11:01:33AM +1300, David Rowley wrote: > On 13 November 2018 at 10:39, Thomas Munro > wrote: > > ... and it has just been voted into the next revision of the C language: > > > > https://gustedt.wordpress.com/2018/11/12/c2x/ > > Nice. Maybe we can get DECFLOAT into core

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread Andres Freund
Hi, On 2018-11-12 23:51:35 +0100, David Fetter wrote: > On Tue, Nov 13, 2018 at 11:01:33AM +1300, David Rowley wrote: > > On 13 November 2018 at 10:39, Thomas Munro > > wrote: > > > ... and it has just been voted into the next revision of the C language: > > > > > >

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread David Fetter
On Mon, Nov 12, 2018 at 02:57:37PM -0800, Andres Freund wrote: > Hi, > > On 2018-11-12 23:51:35 +0100, David Fetter wrote: > > On Tue, Nov 13, 2018 at 11:01:33AM +1300, David Rowley wrote: > > > On 13 November 2018 at 10:39, Thomas Munro > > > wrote: > > > > ... and it has just been voted into

Re: [HACKERS] Decimal64 and Decimal128

2018-11-12 Thread Andres Freund
On 2018-11-13 00:01:49 +0100, David Fetter wrote: > On Mon, Nov 12, 2018 at 02:57:37PM -0800, Andres Freund wrote: > > Hi, > > > > On 2018-11-12 23:51:35 +0100, David Fetter wrote: > > > On Tue, Nov 13, 2018 at 11:01:33AM +1300, David Rowley wrote: > > > > On 13 November 2018 at 10:39, Thomas

Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation

2018-11-12 Thread Jürgen Strobel
On 2018-11-12 17:33, Tom Lane wrote: > Alvaro Herrera writes: >> One of the guiding principles that I think we should hold for >> partitioning is that operating directly into the partition should be >> seen as only an optimization compared to inserting into the parent table >> -- thus it should