Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 220959FB5E8 for ; Wed, 16 May 2007 06:11:35 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 33468-08 for ; Wed, 16 May 2007 06:11:29 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from py-out-1112.google.com (py-out-1112.google.com [64.233.166.179]) by postgresql.org (Postfix) with ESMTP id 69C379FB483 for ; Wed, 16 May 2007 06:11:29 -0300 (ADT) Received: by py-out-1112.google.com with SMTP id a73so422993pye for ; Wed, 16 May 2007 02:11:28 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:disposition-notification-to:date:from:user-agent:mime-version:to:subject:content-type:content-transfer-encoding; b=ZOp4zIhG+ls7ApXOGtuNKpnKyk5qY63YwICLlntVqb8acPXTCeHqzinahqmm9BmdmHFt9v3iBDS3VqBRrx7mHHwXJlWlcwv6vz6sAAFF0ZXExezV/4zOahAVjfwQ65BSSdtcJXrxKA99KmluFQc5F9qLqihC40zu9cyh1sHwBqw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:disposition-notification-to:date:from:user-agent:mime-version:to:subject:content-type:content-transfer-encoding; b=NA7stQK3COYeZvftO231ggSz0anzL1VsZFwk/+9JlEFK9HV20ZcCSCdO064UUw5MTJLl1q4R1XRB8d2mic2bpmv6n4Q4uOt1YmjLtANzVsO142dzcRDTJ+bWmftn7FXQNDsQMgbYkXm/v+DRTsGMUZi8VJ/tKM2J3aUu0XdPD4A= Received: by 10.35.66.1 with SMTP id t1mr14717888pyk.1179306687658; Wed, 16 May 2007 02:11:27 -0700 (PDT) Received: from ?222.71.189.94? ( [222.71.189.94]) by mx.google.com with ESMTP id f6sm3335427pyh.2007.05.16.02.11.23; Wed, 16 May 2007 02:11:26 -0700 (PDT) Message-ID: <464ACA98.40000@gmail.com> Date: Wed, 16 May 2007 17:10:48 +0800 From: =?gb18030?Q?=C0=EE=D1=E5_Ian_Li?= User-Agent: Icedove 1.5.0.10 (X11/20070329) MIME-Version: 1.0 To: pgsql-php@postgresql.org Subject: Data Type for "flags" Content-Type: text/plain; charset=GB18030; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200705/5 X-Sequence-Number: 3794 Hello all: I am new to PHP and PostgereSQL with some former experiences of ASP and MSSQL. My question is when I want to represent different types of object, or different status of object in my application, e.g. class of users, I used to use tinyint in MSSQL. But I found there is no such thing in PGSQL, so what should I use instead? integer, bytea ,or bit(n)? I think integer will be the most convenient to use, isn't it? Regards, Ian