Re: Converting MySQL tinyint to PostgreSQL - Mailing list pgsql-general

From Tom Lane
Subject Re: Converting MySQL tinyint to PostgreSQL
Date
Msg-id 18977.1121177971@sss.pgh.pa.us
Whole thread Raw
In response to Converting MySQL tinyint to PostgreSQL  (Joe <svn@freedomcircle.net>)
List pgsql-general
Joe <svn@freedomcircle.net> writes:
> I have a MySQL database that I'm converting to PostgreSQL which has 10 columns
> with TINYINT type, i.e., a one-byte integer.

> I'm wondering what would be the best conversion choice for these columns:
> smallint, numeric(1), char(1), something else?

smallint, for sure; the others have more overhead.

> BTW, is TINYINT part of any SQL Standard?

No.  If it were, we'd feel more urgency about implementing it ;-)

            regards, tom lane

pgsql-general by date:

Previous
From: "Ets ROLLAND"
Date:
Subject: Pb with boolean between MS-Access and PostgreSQl 8.0.3
Next
From: Dawid Kuroczko
Date:
Subject: Re: Converting MySQL tinyint to PostgreSQL