Typo3: strange ghost column for 1:n relations


January 29, 2015 at 13:35
Typo3

Today I spent hours trying to figure out why a relation wasn't working. I have a table comments and a table fe_users, and a user can post a comment, therefore user:comment => 1:n. I had everything configured appropriately, yet $user->getComments() was always empty. Well, Typo3 is so stupid, it still needs the "ghost column" for relations, a column which is called as my relation objectstorage ("comments" in this case), but which contains essentially nothing. I thought that whatever that column contains doesn't matter, but it turns out: I was wrong. If there is a null value in this column, it seems to fail to make a relation. The value must always be 0. Holy crap, that is so stupid.

Tags: column empty entities extbase relation


Hinterlasse einen Kommentar:
Search