Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f9ElO-0003HL-AP for pgsql-general@arkaria.postgresql.org; Thu, 19 Apr 2018 18:58:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f9ElM-0002tQ-QQ for pgsql-general@arkaria.postgresql.org; Thu, 19 Apr 2018 18:58:32 +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_SHA384:256) (Exim 4.89) (envelope-from ) id 1f9ElM-0002tG-I9 for pgsql-general@lists.postgresql.org; Thu, 19 Apr 2018 18:58:32 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f9ElJ-0000Ay-2f for pgsql-general@postgresql.org; Thu, 19 Apr 2018 18:58:31 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 3A53E20EC0; Thu, 19 Apr 2018 14:58:26 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Thu, 19 Apr 2018 14:58:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=x0rPhFu+I65zvf/igTCmLAOKuEcG4 7+jTDGpCPpflSQ=; b=DUBBJdIvH6xy1mUOX7No7mGDa806Ri3QzjadXBdZLyouc kWUC/pK5BnupdY9R8bwbLV96qzWrl/IsFsYjSGOSOwD2JjnDp73sM2ZUKi7ueA4l fVFM/7IY8JVo6ABKeV/UbjWk0VE9aTjKqLoIjaEcL1rz0VxHESlDMcX+JAFkrS2r HSpdikeNA5XVi45ZFqwW4GLXC/xtIY0HqvXbd0vOJ3kJvbr0xhyDYDt3SYRONn1D PY141Iwj8HWI+iWyUGUnyrCAjiJlU2ANDb4/bTHtrpWXt2iGOv8ejDHZfVXmQLHl oTcS0TK0lzauE3qzBMsFfljkYQbla4JKCS14bi8SQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=x0rPhF u+I65zvf/igTCmLAOKuEcG47+jTDGpCPpflSQ=; b=Qhuf9GamWBviUaGIwYIW9W 68kF3P/llgn5pvgTj/Ej7lf+RV1B24vHed+xwLtIzRQ81M+Ykyj+/gwiTSXNIBoF u3XCohMvrbG+MvksPKGwCLKn97ch1jiihSTNWm8m4QsdPncKdTAccJpO5WQrYycH OdoAI3IBI3AU9PEQzsHy2X/2GEH5qwnV4Nd/LglAqgamlbl/dmTqotXxjTQVfV/Y QtM603KJttVRJz/npOPio78NKkzucb2zCB9ydHqXkX594m6jl9W8OfSwmSW3wX67 CxBibqQfIhYcLMvJ3QPRKhYI/7hdvZXPsKxlVHsXq4FgN/aBzXCRk/HDNaJ5+WKw == X-ME-Sender: Received: from ranger.suse (c-73-239-117-238.hsd1.wa.comcast.net [73.239.117.238]) by mail.messagingengine.com (Postfix) with ESMTPA id B1D4DE443C; Thu, 19 Apr 2018 14:58:25 -0400 (EDT) Subject: Re: Problem with trigger makes Detail record be invalid To: PegoraroF10 , pgsql-general@postgresql.org References: <1524160534707-0.post@n3.nabble.com> <7cb5806e-7371-5c19-1c7b-b8ac556bdfb5@aklaver.com> <1524162628880-0.post@n3.nabble.com> <5cae1bca-4536-bc12-e74f-12a2fff95452@aklaver.com> <1524163929384-0.post@n3.nabble.com> From: Adrian Klaver Message-ID: <6225255e-5091-332f-734f-e55cab7e7f44@aklaver.com> Date: Thu, 19 Apr 2018 11:58:24 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <1524163929384-0.post@n3.nabble.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 04/19/2018 11:52 AM, PegoraroF10 wrote: > My point of view that there was a partial rollback, just on detail table. If > I´ve done a delete from Master and I have a foreign key to it with cascade > option, or all records should be deleted or no one should, this is my point. Except you now have a trigger or possibly triggers that are altering the delete process and possibly counteracting the system trigger that is a FK. There have been enough instances of this show up on this list for me to know this is a distinct possibility. > > Did you see that Master table has no records and Detail table has one record > ? > I think you agree with me that we have a a detail record with no master, so > it´s unusable, right ? We have not seen the actual records, so I cannot say or agree/disagree. > > I´m not able to do a backup/restore of this database because that record > doesn´t match. > > > > -- > Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html > -- Adrian Klaver adrian.klaver@aklaver.com