Simon Riggs wrote:

Neil Conway wrote:
Why is that necessary?

So you can choose whether to do this or not. IMHO, it is important to have
the optimization, but it shouldn't be the case that EVERY statement is
forced not to log.


If I risk data loss, I'd like it to be my choice to do this. This effects
COPY and CREATE INDEX also, though I know you aren't working on those at
present. I will implement thos eif tyou do this for CTAS.

If I understand the original proposal correctly, there is no risk of data loss except in a temporary file. The data would be copied into a new file (without wal-logging), but after that, the file would be fsynced and the resulting changes would indeed be logged to WAL.


So if there is a crash during the copy, nothing valuable will be lost at all. If there is a crash after transaction commit of that transaction, nothing will be lost, again... the new file will have been fsynced already and everything else will be in WAL.

Best Regards,
Michael Paesold



---------------------------(end of broadcast)--------------------------- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Reply via email to