Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iyeXP-0004md-Iq for pgsql-general@arkaria.postgresql.org; Mon, 03 Feb 2020 16:25:28 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iyeWQ-0003sD-Dp for pgsql-general@arkaria.postgresql.org; Mon, 03 Feb 2020 16:24:26 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iyeWQ-0003s6-0z for pgsql-general@lists.postgresql.org; Mon, 03 Feb 2020 16:24:26 +0000 Received: from stz-bg.com ([46.40.123.212] helo=mail.stzbg.com) by magus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1iyeWN-0001jm-1h for pgsql-general@lists.postgresql.org; Mon, 03 Feb 2020 16:24:25 +0000 Received: from www.stz-bg.com (stz-bg.com [IPv6:2a02:6800:0:99::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: condor@stz-bg.com) by mail.stzbg.com (Postfix) with ESMTPSA id B90322E1793 for ; Mon, 3 Feb 2020 18:24:21 +0200 (EET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=stz-bg.com; s=mail; t=1580747061; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LbIjd1pDeaAWezkmZImoLU+o3adpzKObMBfha9cxQf4=; b=fjM5Dxm7vH+PYmd1Sa4+tSN17B4Tm68ne4mzZafSYDuvn/I9hE5tmo6CdlOYRWdksguL3K YneVYv/M/FscZzaI506nhSIFumB9xw9rQIO4DjzDRXJ9o7B8yjoPxQ4TOd5B7upN458zvi 1ivbiZLnIggN42I6fQa4XM6BzsZGi3o= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 03 Feb 2020 18:24:21 +0200 From: Condor To: pgsql-general@lists.postgresql.org Subject: Re: How to avoid UPDATE on same data in table ? In-Reply-To: References: <1a25799e60c79c65575f6e6375c96a52@stz-bg.com> <22cd5ff9ef7651d08628567eafad0de1@stz-bg.com> User-Agent: Roundcube Webmail/1.4.2 Message-ID: <62ebca7bbcd3e89c00d5db9fd8f35479@stz-bg.com> X-Sender: condor@stz-bg.com List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 03-02-2020 10:29, Andrei Zhidenkov wrote: > Have you tried to use built-in suppress_redundant_updates_trigger[1] > for this? > > 1. https://www.postgresql.org/docs/12/functions-trigger.html > No, solution point me Adrian Klaver it's working for me. I look at page, but this probably is build in function and can't be changed. In my case I need to change lastchange column to know which row is changed and when. Regards, HS