[TYPO3-dev]  Field type in MM-tables
    Steffen Müller 
    typo3 at t3node.com
       
    Thu Jul 23 15:52:59 CEST 2009
    
    
  
Hi.
I code an extension using MM-tables. I decided to use the naming scheme
of extbase for my tables, keeping a later transition in mind.
A tablename for example is: tx_myextension_domain_model_mytablename
The MM-table was created by the kickstarter. In my case, the field type
for tablenames and ident (varchar(30)) were too short:
CREATE TABLE tx_myextension_domain_model_mytablename_relations_mm (
        uid_local int(11) unsigned DEFAULT '0' NOT NULL,
        uid_foreign int(11) unsigned DEFAULT '0' NOT NULL,
        sorting int(11) unsigned DEFAULT '0' NOT NULL,
        sorting_foreign int(11) unsigned DEFAULT '0' NOT NULL,
        tablenames varchar(30) NOT NULL,
        ident varchar(30) NOT NULL,
        KEY uid_local (uid_local),
        KEY uid_foreign (uid_foreign)
);
My tablename is 39 charcters long, but tablenames only allows 30.
MySQL itself limits a tablename to 64 characters.
TYPO3 Core API docs also uses 30 characters in its examples.
Is this a neccessary limitation of TCA?
What sense does it make?
Or is iot just a misconfiguration in kickstarter and TYPO3 core API
docs? Otherwise I guess we'll often run into this problem with extbase
naming scheme.
-- 
cheers,
Steffen
TYPO3 Blog: http://www.t3node.com/
Blubber on Twitter: http://twitter.com/t3node
    
    
More information about the TYPO3-dev
mailing list