[TYPO3-mvc] How to handle reserved words in field definitions? (Kickstarter)

Jochen Rau jochen.rau at typoplanet.de
Thu Feb 18 09:32:16 CET 2010


Hi,

I am implementing a rather huge domain with the new Kickstarter right 
now. It works well (nice work Ingmar and Sebastian x 2!). But I stumbled 
upon an annoying issue: reserved words in field definitions.

I have a property "usage" which I can not alter as it follows a standard 
(OASIS CIQ 3.0). But "usage" is a reserved word in MySQL, too. Well, how 
to solve this issue.

1) We can add backtics `usage` to the field definition.
Not a really good solution, as the core doesn't prefix fields at many 
places.

2) We can add a prefix to every (property related) field, like 
tx_myext_usage.
This is my preferred solution now, as we solve another issue coming up 
with extendability of domain models. We have to handle that 
transparently inside Extbase, so that you never get in touch with the 
prefix if you not look at your database ;-).

3) [Any other suggestions]


Jochen


More information about the TYPO3-project-typo3v4mvc mailing list