Hello!

On Fri, Oct 19, 2007 at 09:39:05AM +0200, Markus Gritsch wrote:
> in SQLObject a BoolCol() is stored as TINYINT(4) in the MySQL backend
> and as TINYINT in the SQLite backend.  Both are not optimal IMO:

   Booleans are stored as TINYINT which is TINYINT(1). Why do you think it
is TINYINT(4)?!

See http://dev.mysql.com/doc/refman/4.1/en/numeric-types.html

> *) MySQL knows BOOL (and since version 4.1 also BOOLEAN), which is a
> synonym for TINYINT(1).
> (http://dev.mysql.com/doc/refman/4.1/en/numeric-type-overview.html)

   Ok. As they're only synonyms I think I can use them in the current
branches. Expect a new round of betas today or in a few days.

> *) TINYINT is not part of ANSI SQL and should IMO therefore not be
> used in the SQLite backend.  SQLAlchemy uses BOOLEAN.

   Due to "column affinity" I'd better use a name that contains "INT"
- just INT(1) or INTEGER(1): http://sqlite.org/datatype3.html
   Ok?

Oleg.
-- 
     Oleg Broytmann            http://phd.pp.ru/            [EMAIL PROTECTED]
           Programmers don't die, they just GOSUB without RETURN.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
sqlobject-discuss mailing list
sqlobject-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss

Reply via email to