X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id C3BBD53830 for ; Sat, 26 Mar 2005 15:14:46 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 65835-07 for ; Sat, 26 Mar 2005 15:14:45 +0000 (GMT) Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.116.145.2]) by svr1.postgresql.org (Postfix) with ESMTP id 505CE53811 for ; Sat, 26 Mar 2005 15:14:42 +0000 (GMT) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id BB75F30950; Sat, 26 Mar 2005 16:14:41 +0100 (MET) From: "Andrus Moor" X-Newsgroups: pgsql.sql Subject: How to make update statement to work Date: Sat, 26 Mar 2005 17:13:19 +0200 Organization: Hub.Org Networking Services Lines: 19 Message-ID: X-Complaints-To: usenet@news.hub.org X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2180 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 To: pgsql-sql@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=1.237 tagged_above=0 required=5 tests=AWL, PRIORITY_NO_NAME X-Spam-Level: * X-Archive-Number: 200503/344 X-Sequence-Number: 20823 I want to nullify fields which does not exist in reference table. I tried UPDATE demo.toode SET "liik"=NULL, "grupp"=NULL WHERE ("grupp", "liik") NOT IN (SELECT ("grupp", "liik") FROM "artliik") but this causes error: ERROR: operator does not exist: character = record HINT: No operator matches the given name and argument type(s). You may need to add explicit type casts. How to write this UPDATE statement properly ?