lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Horváth Péter Gergely <>
Subject Creating dynamic field, but strip the type indicator postfix from the name
Date Thu, 19 May 2016 12:59:13 GMT
Hi Everyone,

I am wondering if it is possible to store dynamic fields without the type
indicator postfix. In our Solr environment, I would like to
1.) use dynamic fields ("data drivern collections" with no fixed fields
specified in advance)
2.) be able to specify the field type, but without interacting with Solr
schema API separately
3.) I do not want type indicator postfixes to appear in field names, since
that would make queries more complicated to form.

For example, I could imagine that when I add a document like this:

        CloudSolrClient solr  = ...

        SolrInputDocument document = new SolrInputDocument();

        document.addField("foobar_s", "theValue")

        solr.add("someCollection", document);

Solr would recognize that the "foobar_s" field name contains a type
indicator and it would create a field named "foobar" with the type of

Is there any way to achieve this behavior (have Solr create the field with
the requested type, but without the type indicator postfix)? If yes, how
could I do that?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message