Issue Bug Closed

#68643Non-existing fields _ORIG_pid and _ORIG_uid in SQL statement

Albrecht Köhnlein 07/30/15, 16:01 updated 10/02/18, 11:35

Description

I have an extension where I added IRRE elements to tt_content and inside this IRRE elements, I have FAL relations.

tt_content
- IRRE: topics
-- FAL relations

When I change the topic records inside a workspace, I don’t see the FAL relations anymore. But there is an SQL error:

> SELECT uid, pid, content, title, description, file, preview, tstamp, crdate, cruser_id, deleted, hidden, starttime, endtime, t3ver_oid, t3ver_id, t3ver_wsid, t3ver_label, t3ver_state, t3ver_stage, t3ver_count, t3ver_tstamp, t3ver_move_id, sorting, sys_language_uid, l10n_parent, l10n_diffsource, accessory, limit_to_region, limit_to_region_mode, _ORIG_pid, _ORIG_uid FROM tx_myextension_domain_model_topic WHERE pid=-1 AND t3ver_oid=502 AND t3ver_wsid=24 AND tx_myextension_domain_model_topic.deleted=0 LIMIT 1

As you can see there are the fields _ORIG_pid and _ORIG_uid added to the statement, but they don’t exist in database.

The problem is, in function PageRepository::versionOL(), the field list is built including this two non-existing fields. When I change the implode() stuff into wildcard ‘*’, everything works fine.

Reviews 2