X-Original-To: pgsql-interfaces-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 2151C9FA5C3 for ; Sun, 11 Jun 2006 08:33:03 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 87880-02 for ; Sun, 11 Jun 2006 08:32:54 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sydney.mailnetwork.co.uk (server88-208-192-113.live-servers.net [88.208.192.113]) by postgresql.org (Postfix) with ESMTP id 5DA1E9F9CAA for ; Sun, 11 Jun 2006 08:32:54 -0300 (ADT) Received: from andyshellam-gw.adsl.newnet.co.uk ([80.175.198.137]:1203 helo=[192.168.1.5]) by sydney.mailnetwork.co.uk with esmtpa (Exim 4.60) (envelope-from ) id 1FpOBZ-0006ee-0L for pgsql-interfaces@postgresql.org; Sun, 11 Jun 2006 12:32:53 +0100 Message-ID: <448BFF62.8030606@andycc.net> Date: Sun, 11 Jun 2006 12:32:50 +0100 From: Andy Shellam Reply-To: andy@andycc.net Organization: AndyShellam.EU User-Agent: Thunderbird 1.5.0.4 (Windows/20060516) MIME-Version: 1.0 To: pgsql-interfaces@postgresql.org Subject: Npgsql MS 2.0 - char bug? X-Enigmail-Version: 0.94.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200606/12 X-Sequence-Number: 6153 Hi, I'm running the MS .NET 2.0 version of Npgsql (1.0RC1) with Visual Basic 2005. My primary key (domain_id) in the "domain" table is defined as char(10). I have the query: UPDATE domain SET domain = :domain, last_updated_user = CURRENT_USER, last_updated_date = NOW() WHERE domain_id = :domain_id; And the parameters are defined as: :domain -> Name: "domain" -> Type: varchar -> Size: 200 -> sourceColumn: "domain" :domain_id -> Name: "domain_id" -> Type: char -> Size: 10 -> sourceColumn: "domain_id" That fails with the error "the UpdateCommand affected 0 of 1 rows expected." The same with the DeleteCommand. If I change the parameter ":domain_id" to... :domain_id -> Name: "domain_id" -> Type: varchar -> Size: 10 -> sourceColumn: "domain_id" ... it works on both. Is this a bug, or am I missing something? Thanks Andy