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 DF43C329D20 for ; Fri, 17 Sep 2004 23:07:38 +0100 (BST) 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 30761-05 for ; Fri, 17 Sep 2004 22:07:33 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id EFF91329D15 for ; Fri, 17 Sep 2004 23:07:35 +0100 (BST) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i8HM7WCn033271 for ; Fri, 17 Sep 2004 22:07:32 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i8HLefiP026227 for pgsql-sql@postgresql.org; Fri, 17 Sep 2004 21:40:41 GMT From: stig erikson X-Newsgroups: comp.databases.postgresql.sql Subject: 1-byte integers Date: Fri, 17 Sep 2004 23:40:45 +0200 Organization: Hub.Org Networking Services Lines: 14 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@news.hub.org User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8a4) Gecko/20040916 X-Accept-Language: en-us, en, sv, nn, nb, no, pl X-Enigmail-Version: 0.86.0.0 X-Enigmail-Supports: pgp-inline, pgp-mime To: pgsql-sql@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200409/119 X-Sequence-Number: 18965 how can i specify an integer to be one byte byte or even 4 bits long? int1, int(1), tinyint are nowhere to be seen. smallest i can find is smallint that is 2 bytes. in a table i will have a few columns with values between 0 and 15, so optimally i am looking for some kind of unsigned 4-bits, or (un)signed integer (1-byte). i can live with smallint for a while but estimate a few millions of rows in the table to be a reality soon, in such cases every byte matters. is there some stig