From: | Isaac Morland <isaac(dot)morland(at)gmail(dot)com> |
---|---|
To: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | "Yotsunaga, Naoki" <yotsunaga(dot)naoki(at)jp(dot)fujitsu(dot)com>, Postgres hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: automatic restore point |
Date: | 2018-06-26 03:01:06 |
Message-ID: | CAMsGm5cbv6BwqzsUHGVDUvn5yMePhyZBCfPhND88QAWv6MqwOA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 25 June 2018 at 21:33, David G. Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
wrote:
> On Mon, Jun 25, 2018 at 6:17 PM, Yotsunaga, Naoki <
> yotsunaga(dot)naoki(at)jp(dot)fujitsu(dot)com> wrote:
>
>>
>> So what do you think about it? Do you think is it useful?
>>
>
> I'd rather spend effort making the initial execution of said commands less
> likely. Something like:
>
> TRUNCATE table YES_I_REALLY_WANT_TO_DO_THIS;
>
I think an optional setting making DELETE and UPDATE without a WHERE clause
illegal would be handy. Obviously this would have to be optional for
backward compatibility. Perhaps even just a GUC setting, with the intent
being that one would set it in .psqlrc so that omitting the WHERE clause at
the command line would just be a syntax error. If one actually does need to
affect the whole table one can just say WHERE TRUE. For applications, which
presumably have their SQL queries tightly controlled and pre-written
anyway, this would most likely not be particularly useful.
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2018-06-26 04:02:35 | Re: Few cosmetic suggestions for commit 16828d5c (Fast Alter Table Add Column...) |
Previous Message | Kyotaro HORIGUCHI | 2018-06-26 02:41:22 | Re: PATCH: backtraces for error messages |