[TYPO3-dev] Request for cleanup of typo3 database schema

Sven Wilhelm wilhelm at modulebox.com
Mon Mar 12 19:50:41 CET 2007


> FYI: The number in brackes does not signify the range of the integer,
> but the default column width used in the shell. It can be omitted. And
> INTEGER is just a synonyum for INT.
yes, I know, but defining the display with should't be part of an sql
definition.

Real sql datatypes are:

bit, bit varying, boolean, char, character varying, character, varchar,
date, double precision, integer, interval, numeric, decimal, real,
smallint, time, timestamp

ok, you can use smallint (2bytes on postgres) for some tinyints, but as the
most fields described as tinyints are booleans, its' more intelligent to
define them as boolean and use integer (4bytes on postgres) to define the
rest (real integers) without the column with.

I know that the difference between your thoughts and my thoughts about the
facts above is:

you: install a typo3 instance and use the typo3 installer to setup the
database

me: let a tool on the shell do the job and let it import the sql files.
    if they are unnecessary, why do they still exist???
    because for automated tasks, the typo3 shell api isn't really powerful

so there are two possible ways to solve the automation:

1) have a universal sql file that is working on 3 or 4 major dbs
2) have an abstract definition an render a db specific sql schema

at the moment I prefer 1)

sven





More information about the TYPO3-dev mailing list