Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W8tke-00013A-A9 for pgsql-sql@arkaria.postgresql.org; Thu, 30 Jan 2014 15:42:00 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1W8tkd-0004DK-Mb for pgsql-sql@arkaria.postgresql.org; Thu, 30 Jan 2014 15:41:59 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W8tkc-0004DD-Eo for pgsql-sql@postgresql.org; Thu, 30 Jan 2014 15:41:58 +0000 Received: from mail-pb0-x235.google.com ([2607:f8b0:400e:c01::235]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W8tkR-0007pG-EG for pgsql-sql@postgresql.org; Thu, 30 Jan 2014 15:41:57 +0000 Received: by mail-pb0-f53.google.com with SMTP id md12so3235324pbc.40 for ; Thu, 30 Jan 2014 07:41:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=SBieWGAy4WsuV3qeDQ8qzHX+U+bnZeDsUZJ3shkQ9Cs=; b=l24C6fuhTc6wYZz0tvEJ0fZeOESkitS5KO3n0LsjzzAM0b/wFxKU+LQvDk6ExQ7b/H qSkc1mDpH1Zr8Q4Cet8Ejrd1vIvqZ4rXYoiBiX0I0v7MDnUQbVe4bLVI75orJyG9CPQa 9Xvs4OCrp+eGI3hPHT7rtk4E226h42KBoEVMs+n59hIemR6JgLjdCbDLNKWJV50V7Q9T Gnb3nsb2Ye1+eU1a/WBjAEOcRH3+SrlqoqXqXgum/UZ8LsHP3+ZHFrLHIUKsDwKbEWs5 ZOyJMxjNTHCASGgFLAl9aRU2JE0mIIbeVTuuManJMvQJ63INvAmNYYmh8+3vXXCgdiKQ a56A== X-Received: by 10.68.133.229 with SMTP id pf5mr15109437pbb.115.1391096505888; Thu, 30 Jan 2014 07:41:45 -0800 (PST) Received: from panda.site (65-102-185-39.tukw.qwest.net. [65.102.185.39]) by mx.google.com with ESMTPSA id hb10sm18572924pbd.1.2014.01.30.07.41.44 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 30 Jan 2014 07:41:45 -0800 (PST) Message-ID: <52EA72B5.5040304@gmail.com> Date: Thu, 30 Jan 2014 07:41:41 -0800 From: Adrian Klaver User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Bob Spero , pgsql-sql@postgresql.org Subject: Re: How to detect values changed in field of foreign table? References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.0 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-sql Precedence: bulk Sender: pgsql-sql-owner@postgresql.org On 01/26/2014 04:20 PM, Bob Spero wrote: > I have an oracle foreign table that holds arbitrary tasks, when a task > gets updated the "time_update" field will change. I want to detect when > the field changes so I can insert the values in a local table for > completed tasks. Can postgresql detect changes in a foreign table so a > trigger can be invoked? I am new to postgrwsql so any examples or > education on what steps to take to complete tjos would be greatly > appreciated! Well there is a patch in the current CommitFest to add trigger support to Foreign Tables. Assuming it gets committed it will not be available until 9.4. Not sure how else you could accomplish what you want. More information would be useful for those folks that might have clue. So: What versions of Postgres, Oracle? What fdw are using to make the connection? -- Adrian Klaver adrian.klaver@gmail.com -- Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-sql