Add field types to index metadata #190

Closed
Tom9729 opened this Issue Feb 14, 2014 · 1 comment

2 participants

@Tom9729

I am working on a translator for Teiid (http://www.jboss.org/teiid/) to expose a c-l instance as a relational data source: each index is a table, fields are columns, SQL is translated to Lucene queries. I am pulling the fields from the index metadata as described in the docs:

"fields":["foo","bar"]

I need to know the types of the fields (eg. string, date, long). Currently I am encoding it in the name:

"fields":["foo.long","bar.date"]

It would be helpful if instead, the fields could be returned with more information like this:

"fields":[{"field":"foo","type":"long"},{"name":"bar","type":"date"}]

@rnewson
Owner

The types are not known, sadly. Lucene (at least until version 4.0) deals only with strings. It's why the query-time sort parameter requires type hints.

@Tom9729 Tom9729 closed this Feb 14, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment