Received: from teapot06.domain1.bigpond.com (teapot06.domain1.bigpond.com [139.134.5.237]) by mail.postgresql.org (8.11.1/8.11.1) with SMTP id f0A7DVB00974 for ; Wed, 10 Jan 2001 02:13:32 -0500 (EST) (envelope-from aa2@bigpond.net.au) Received: from localhost (localhost [127.0.0.1]) by teapot06.domain1.bigpond.com (NTMail 3.02.13) with ESMTP id ta764783 for ; Wed, 10 Jan 2001 17:13:23 +1000 Received: from CPE-144-132-51-31.vic.bigpond.net.au ([144.132.51.31]) by mail1.bigpond.com (Claudes-Legendary-MailRouter V2.9c 1/899216); 10 Jan 2001 17:13:23 Message-ID: <3A5CA5FA.CBDF0513@bigpond.net.au> Date: Thu, 11 Jan 2001 05:12:10 +1100 From: Justin Clift X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.2.17-21mdk i686) X-Accept-Language: en MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: Bad (null) varchar() external representation Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200101/93 X-Sequence-Number: 754 Hi all, I'm getting the following problem when trying to do a simple insert statement... "Bad (null) varchar() external representation" WHY? I'm running PostgreSQL 7.03 on Linux Mandrake 7.2 (using a specially compiled version, not an RPM). Here's the table : foobar=# \d staff_details Table "staff_details" Attribute | Type | Modifier ----------------+--------------+---------- userid | varchar(24) | not null password | char(13) | name | varchar(96) | role | smallint | dob | date | phone_one | varchar(14) | phone_two | varchar(14) | phone_three | varchar(14) | address | varchar(280) | status | smallint | managers_notes | varchar(600) | Index: staff_details_pkey Constraints: (length(userid) < 25) (length("password") < 14) (length(name) < 97) (length(phone_one) < 17) (length(phone_two) < 17) (length(phone_three) < 17) (length(address) < 281) (length(managers_notes) < 601) foobar=# insert into staff_details values ('A', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); ERROR: Bad (null) varchar() external representation foobar=# insert into staff_details (userid, password, name, role, dob, phone_one) values ('0000111122223333', 'foobarbaz1234', 'Joshua', 1, '1970-07-01', '(03) 9867 5432'); ERROR: Bad (null) varchar() external representation foobar=# insert into staff_details values ('0000111122223333', encrypt('foo'), 'Joshua', 1, '1970-07-01', '(03) 9867 5432', '(041) 309 2819', NULL, '1 Blankety-Blank Way\nBazzville', NULL, NULL); ERROR: Bad (null) varchar() external representation etc... I've tried everything I can think of, also exported and reloaded the database, etc. This is a new table with nothing in it. This is driving me nuts. :-( + Justin Clift Database Administrator