You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by Yonik Seeley <yo...@lucidimagination.com> on 2009/12/24 16:44:09 UTC

Re: svn commit: r893781 - /lucene/solr/trunk/example/solr/conf/schema.xml

So, what do people think about adding this documentation to the point
type... helpful? confusing?
Opinions on the example schema... should we use subFieldType (i.e.
have the type create the dynamic field for us) or subFieldSuffix?

-Yonik
http://www.lucidimagination.com

On Thu, Dec 24, 2009 at 10:39 AM,  <yo...@apache.org> wrote:
> Author: yonik
> Date: Thu Dec 24 15:39:51 2009
> New Revision: 893781
>
> URL: http://svn.apache.org/viewvc?rev=893781&view=rev
> Log:
> add doc to point type in example schema
>
> Modified:
>    lucene/solr/trunk/example/solr/conf/schema.xml
>
> Modified: lucene/solr/trunk/example/solr/conf/schema.xml
> URL: http://svn.apache.org/viewvc/lucene/solr/trunk/example/solr/conf/schema.xml?rev=893781&r1=893780&r2=893781&view=diff
> ==============================================================================
> --- lucene/solr/trunk/example/solr/conf/schema.xml (original)
> +++ lucene/solr/trunk/example/solr/conf/schema.xml Thu Dec 24 15:39:51 2009
> @@ -396,8 +396,14 @@
>          any data added to them will be ignored outright.  -->
>     <fieldtype name="ignored" stored="false" indexed="false" multiValued="true" class="solr.StrField" />
>
> -    <!--
> -     A PointType is a Poly Field.  It can either declare a subFieldType or a subFieldSuffix
> +    <!-- This point type indexes the coordinates as separate fields (subFields)
> +      If subFieldType is defined, it references a type, and a dynamic field
> +      definition is created matching *___<typename>.  Alternately, if
> +      subFieldSuffix is defined, that is used to create the subFields.
> +      Example: if subFieldType="double", then the coordinates would be
> +        indexed in fields myloc_0___double,myloc_1___double.
> +      Example: if subFieldSuffix="_d" then the coordinates would be indexed
> +        in fields myloc_0_d,myloc_1_d
>      -->
>     <fieldType name="location" class="solr.PointType" dimension="2" subFieldType="double"/>

Re: svn commit: r893781 - /lucene/solr/trunk/example/solr/conf/schema.xml

Posted by Grant Ingersoll <gs...@apache.org>.
On Dec 24, 2009, at 10:44 AM, Yonik Seeley wrote:

> So, what do people think about adding this documentation to the point
> type... helpful? confusing?

+1.  I also added some to the Wiki on poly fields under the SchemaXML page.

> Opinions on the example schema... should we use subFieldType (i.e.
> have the type create the dynamic field for us) or subFieldSuffix?

Or both?  We could have two different field types, one that uses subFT and on that uses suffix.

> 
> -Yonik
> http://www.lucidimagination.com
> 
> On Thu, Dec 24, 2009 at 10:39 AM,  <yo...@apache.org> wrote:
>> Author: yonik
>> Date: Thu Dec 24 15:39:51 2009
>> New Revision: 893781
>> 
>> URL: http://svn.apache.org/viewvc?rev=893781&view=rev
>> Log:
>> add doc to point type in example schema
>> 
>> Modified:
>>    lucene/solr/trunk/example/solr/conf/schema.xml
>> 
>> Modified: lucene/solr/trunk/example/solr/conf/schema.xml
>> URL: http://svn.apache.org/viewvc/lucene/solr/trunk/example/solr/conf/schema.xml?rev=893781&r1=893780&r2=893781&view=diff
>> ==============================================================================
>> --- lucene/solr/trunk/example/solr/conf/schema.xml (original)
>> +++ lucene/solr/trunk/example/solr/conf/schema.xml Thu Dec 24 15:39:51 2009
>> @@ -396,8 +396,14 @@
>>          any data added to them will be ignored outright.  -->
>>     <fieldtype name="ignored" stored="false" indexed="false" multiValued="true" class="solr.StrField" />
>> 
>> -    <!--
>> -     A PointType is a Poly Field.  It can either declare a subFieldType or a subFieldSuffix
>> +    <!-- This point type indexes the coordinates as separate fields (subFields)
>> +      If subFieldType is defined, it references a type, and a dynamic field
>> +      definition is created matching *___<typename>.  Alternately, if
>> +      subFieldSuffix is defined, that is used to create the subFields.
>> +      Example: if subFieldType="double", then the coordinates would be
>> +        indexed in fields myloc_0___double,myloc_1___double.
>> +      Example: if subFieldSuffix="_d" then the coordinates would be indexed
>> +        in fields myloc_0_d,myloc_1_d
>>      -->
>>     <fieldType name="location" class="solr.PointType" dimension="2" subFieldType="double"/>

--------------------------
Grant Ingersoll
http://www.lucidimagination.com/

Search the Lucene ecosystem using Solr/Lucene: http://www.lucidimagination.com/search