04-22-2022 02:51 AM
It seems that Nuxeo is only using string fields to build the fulltext
. Maybe using the fulltextExcludedTypes
but I cannot find it anywhere being set.
Is there a way I can incorporate number fields, e.g. a year, into the fulltext index? Or specifiy the fields that will go into?
Update: I am using VCS with Postgres
04-26-2022 01:04 PM
Hello,
You should adapt the Elasticsearch mapping as described here: https://doc.nuxeo.com/nxdoc/configuring-the-elasticsearch-mapping/#includeexcluding-a-field-from-the...
As you correctly pointed out, the default full text field only indexes text fields
Regards
07-20-2022 12:26 PM
Hi Gregory,
sorry for the late reply. Did not have the time to look into that until now. Actually, I am not using Elasticsearch, but Postgres' full-text search would be enough for me. Unfortunately, it seems that Nuxeo ignores fields that are not of type string or binary (c.f. FulltextConfigurationFactory.java:176). At least that's my conclusion after getting a
ERROR [FulltextConfigurationFactory] Ignoring property 'datacite:year' with bad type org.nuxeo.ecm.core.schema.types.primitives.LongType@8b41ad in fulltext configuration: year
(datacite:year is a custom field of ours)
My overall goal is to be able to search by year but also in a combined search term like "contract 2020". Do you have any ideas on how to accomplish that?
Best, Konrad
12-15-2022 05:52 AM
For anybody interested: I ended up using a hidden schema text field storing the int year as a string. Because it is a text, it is added to the fulltext search. I use a listener to update that field on any beforeDocumentModification
event
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.