[TYPO3-Solr] SOLR_RELATION question: tt_news & tt_address
Jigal van Hemert
jigal.van.hemert at typo3.org
Mon Jul 1 06:53:19 CEST 2013
Hi,
On 30-6-2013 21:16, Bernhard Karimi wrote:
> The author name is stored in tt_address.name.
> In the tt_news table I have a field tx_newsauthorextended_author, that
> keeps the uid of the author in tt_address. This relation is not in the TCA.
> How can I define this relation for the queueindexer?
I can't imagine that the relationship is not in TCA. I assume you can
select the author in a tt_news record when editing it in the backend?
Anyway, AFAIK SOLR_RELATION relies on the TCA definition to figure out
the relation. If this is not the case for your field then I think you
have two options:
- define the TCA for the relationship in a tiny mini-extension and let
solr figure things out
- use the CONTENT object to query the tt_address table
author_stringM = CONTENT
author_stringM {
table = tt_address
select {
pidInList = nnnn // storage of tt_address records
selectFields = name
where = uid=###authorid###
markers {
authorid.field = tx_newsauthorextended_author
}
}
renderObj = TEXT
renderObj.field = name
}
--
Jigal van Hemert
TYPO3 CMS Active Contributor
TYPO3 .... inspiring people to share!
Get involved: typo3.org
More information about the TYPO3-project-solr
mailing list