Subject | Re: [firebird-support] A few Firebird questions about future features |
---|---|
Author | Milan Babuskov |
Post date | 2008-01-09T09:49:35Z |
javaguru_uk wrote:
CREATE DOMAIN BOOLEAN
AS SMALLINT
CHECK (value is null or value in (0, 1));
And use it like this:
CREATE TABLE t1
(
C1 VARCHAR(10),
B1 BOOLEAN,
B2 BOOLEAN NOT NULL,
...
);
As you can see, not much different than 'real' boolean.
--
Milan Babuskov
http://www.flamerobin.org
> Are there any plans to add support for true booleans? If yes, whichYou can easily add boolean type via domains:
> version will support this?
CREATE DOMAIN BOOLEAN
AS SMALLINT
CHECK (value is null or value in (0, 1));
And use it like this:
CREATE TABLE t1
(
C1 VARCHAR(10),
B1 BOOLEAN,
B2 BOOLEAN NOT NULL,
...
);
As you can see, not much different than 'real' boolean.
--
Milan Babuskov
http://www.flamerobin.org