[TYPO3-mvc] How to handle reserved words in field definitions? (Kickstarter)
Steffen Ritter
info at rs-websystems.de
Thu Feb 18 10:28:09 CET 2010
Jochen Rau schrieb:
> 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.
in general i think this should be the way to go, since it is the "most
clean" solution.
If core is not "able" to handle this, we might add it in Core. Probably
this makes it easier for dbal and Xavier too.
But he's the Database expert und should comment on that.
> 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 ;-).
please Do NOT!
> 3) [Any other suggestions]
add a "reserved words" lists, which is checked. there always another
naming for the property may be found, meaning the same.
>
> Jochen
Steffen
More information about the TYPO3-project-typo3v4mvc
mailing list