Hello!

I was wondering if any of you had any ideas on why my "size" facets are coming back without any decimal points in their names. For example, my 7.5s come back as 75. 

Very strange. 

You can see, right below the size facet is a brand facet with a name of "Vans". As far as I can tell, both the brand_exact and the size are stored in the index the same exact way, except that the sizes are multivalued. 

I've also attached my schema file. I'm using SOLR 1.2. You can see the "front end display" of this install at https://prelive.canada.zappos.com/n/solr.cgi  (check it out, let me know if you find anything weird... heh)

+--------------------------------------------------------+
 | Matthew Runo
 | Zappos Development
 | 702-943-7833                                                 
+--------------------------------------------------------+

<?xml version="1.0" encoding="UTF-8"?>
<response>
<lst name="responseHeader"><int name="status">0</int><int name="QTime">2</int><lst name="params"><str name="facet">true</str><str name="facet.mincount">1</str><str name="facet.limit">5</str><str name="rows">100</str><arr name="facet.query"><str>price:[1 TO 50]</str><str>price:[50 TO 100]</str><str>price:[150 TO 200]</str><str>price:[200 TO 250]</str><str>price:[250 TO 300]</str><str>price:[300 TO *]</str></arr><str name="start">0</str><str name="q">blue</str><arr name="facet.field"><str>size</str><str>brand_exact</str></arr><str name="qt">dismax</str><arr name="fq"><str>brand_exact:"Vans"</str><str>country_code:US</str><str>price:[50 TO 100]</str><str>brand_exact:"Vans"</str></arr></lst></lst><result name="response" numFound="20" start="0" maxScore="1.1481537"><doc><float name="score">1.1481537</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Navy/Della Blue Leather</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt; &lt;li&gt;A contemporary classic with rock star attitude. &lt;li&gt;The TNT redefines a vintage design with quality materials and supporting construction. &lt;li&gt;Endorsed by &lt;i&gt;Thrasher&lt;/i&gt; Skater of the Year all-terrain destroyer Tony Trujillo. &lt;/ul&gt;</str><str name="name">TNT</str><float name="price">59.95</float><int name="product_id">114373</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/114373/c/59967.html</str><str name="thumbnail_url">/images/114/114373/3832-236500-t.jpg</str></doc><doc><float name="score">1.1481537</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Navy/Della Blue Leather</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt; &lt;li&gt;A contemporary classic with rock star attitude. &lt;li&gt;The TNT redefines a vintage design with quality materials and supporting construction. &lt;li&gt;Endorsed by &lt;i&gt;Thrasher&lt;/i&gt; Skater of the Year all-terrain destroyer Tony Trujillo. &lt;/ul&gt;</str><str name="name">TNT</str><float name="price">59.95</float><int name="product_id">114373</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/114373/c/54979.html</str><str name="thumbnail_url">/images/114/114373/1733-192169-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/3.html</str><str name="thumbnail_url">/images/724/7242176/6220-326959-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/742.html</str><str name="thumbnail_url">/images/724/7242176/4974-262346-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/1247.html</str><str name="thumbnail_url">/images/724/7242176/985-262347-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/2125.html</str><str name="thumbnail_url">/images/724/7242176/4974-326961-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/48880.html</str><str name="thumbnail_url">/images/724/7242176/3034-262348-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Hit the streets in style while rippin' in these skate sneaks.&lt;li&gt;Leather upper with per detail for breathability.&lt;li&gt;Cupsole design.&lt;li&gt;Mesh lined.&lt;li&gt;Durable rubber outsole.&lt;/ul&gt;</str><str name="name">Fastplant</str><float name="price">54.95</float><int name="product_id">7242176</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7242176/c/133.html</str><str name="thumbnail_url">/images/724/7242176/1733-262345-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/1247.html</str><str name="thumbnail_url">/images/727/7277297/4998-326970-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/126.html</str><str name="thumbnail_url">/images/727/7277297/4998-326971-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/850.html</str><str name="thumbnail_url">/images/727/7277297/4998-326975-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/2971.html</str><str name="thumbnail_url">/images/727/7277297/4998-326974-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/48880.html</str><str name="thumbnail_url">/images/727/7277297/6220-326973-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/51986.html</str><str name="thumbnail_url">/images/727/7277297/7768-438685-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/White/Royal Blue</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Suede or suede/leather upper.&lt;li&gt;Quarter underlay detail.&lt;li&gt;Embroidered quarter logo detail.&lt;li&gt;Ghillie lacing system with underlay detail.&lt;li&gt;Cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Hayes</str><float name="price">54.95</float><int name="product_id">7277297</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7277297/c/105272.html</str><str name="thumbnail_url">/images/727/7277297/7768-438684-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/Lake Blue Stars</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Adorable skate kicks.&lt;li&gt;Suede upper with printed side panels.&lt;li&gt;Lightly padded tongue and collar for extra support.&lt;li&gt;Faux vulcanized look on a cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Suri W</str><float name="price">54.95</float><int name="product_id">7298003</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7298003/c/90103.html</str><str name="thumbnail_url">/images/729/7298003/4998-373900-t.jpg</str></doc><doc><float name="score">1.1481482</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/Lake Blue Stars</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Adorable skate kicks.&lt;li&gt;Suede upper with printed side panels.&lt;li&gt;Lightly padded tongue and collar for extra support.&lt;li&gt;Faux vulcanized look on a cupsole construction.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Suri W</str><float name="price">54.95</float><int name="product_id">7298003</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7298003/c/90104.html</str><str name="thumbnail_url">/images/729/7298003/6901-373901-t.jpg</str></doc><doc><float name="score">0.49289522</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Espresso/Gray Mist</str><str>Jungle Green/Dream Blue</str><str>Black/White/Dark Gum</str><str>Charcoal/Mid Grey</str><str>White/Mid Grey</str></arr><arr name="country_code"><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Cool sneaks for skating or chillin'.&lt;li&gt;Leather upper for durability.&lt;li&gt;Padded collar and tongue for added shock absorption.&lt;li&gt;Textile lining.&lt;li&gt;Durable cupsole design.&lt;li&gt;Grippy rubber outsole.&lt;/ul&gt;</str><str name="name">Valiant</str><float name="price">54.95</float><int name="product_id">7242178</int><arr name="product_type"><str>Footwear</str><str>Athletic</str><str>Skate</str></arr><str name="product_url">/n/p/p/7242178/c/21795.html</str><str name="thumbnail_url">/images/724/7242178/3832-262354-t.jpg</str></doc><doc><float name="score">0.32904303</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Coffee/Dried Tobacco</str><str>Black/Formula One</str><str>Coffee/Deep Red</str><str>Black Suede</str><str>Black/Gargoyle</str><str>Smoke/Black</str><str>Black/Mid Grey/White</str><str>Black/Spectra Yellow</str><str>White/Navy</str><str>Black/Royal Blue</str><str>Navy/White</str><str>Smoke/Navy Suede</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt;Features a suede upper. &lt;li&gt;Ghillie lacing system with underlay detail. &lt;li&gt;Double stitched toecap for durability. &lt;li&gt;Die cut EVA midsole. &lt;li&gt;SBR and gum rubber outsole. &lt;/ul&gt;</str><str name="name">Emory</str><float name="price">54.95</float><int name="product_id">7150945</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/7150945/c/4007.html</str><str name="thumbnail_url">/images/945/7150945/1733-162412-t.jpg</str></doc><doc><float name="score">0.2880758</float><str name="brand">Vans</str><int name="brand_id">171</int><arr name="color"><str>Black/Dream Blue</str><str>White/India Ink Tumbled Leather</str><str>White/Red/Light Gum</str><str>Burnt Olive/Fog</str><str>Loden/Wht/Dk Gum Garment Leather</str><str>Blk/Wht/Med Gum Garment Leather</str><str>Black/Betty</str><str>Fog/Chive/White</str><str>Ice Grey/Chicory</str><str>Navy/True Yellow/White</str><str>White/Hot Coral</str><str>Ice Grey/Fern Green/Mid Grey</str><str>Seal Brown/Lead Gray Oil Suede</str><str>Ice Grey/Mid Grey/Confetti</str></arr><arr name="country_code"><str>CA</str><str>US</str></arr><str name="description">&lt;ul&gt;&lt;li&gt; Stylish V-inspired retro groove sneakers with a low-profile outsole, but high-style energy. &lt;li&gt; Garment leather, tumbled leather, or oil suede upper for long durable, comfortable wear. &lt;li&gt; Padded footbed, collar, and tongue for added comfort, support, custom fit, and shock absorption. &lt;li&gt; Polyurethane sole provides great traction. &lt;li&gt; An awesome sneaker, a must have for any wardrobe. &lt;/ul&gt;</str><str name="name">Quincy W</str><float name="price">59.95</float><int name="product_id">126969</int><arr name="product_type"><str>Footwear</str><str>Closed Footwear</str><str>General Closed Footwear</str></arr><str name="product_url">/n/p/p/126969/c/28553.html</str><str name="thumbnail_url">/images/w/wVans74/1729-112045-t.jpg</str></doc></result><lst name="facet_counts"><lst name="facet_queries"><int name="price:[1 TO 50]">0</int><int name="price:[50 TO 100]">20</int><int name="price:[150 TO 200]">0</int><int name="price:[200 TO 250]">0</int><int name="price:[250 TO 300]">0</int><int name="price:[300 TO *]">0</int></lst><lst name="facet_fields"><lst name="size"><int name="10">20</int><int name="11">20</int><int name="5">20</int><int name="7">20</int><int name="75">20</int></lst><lst name="brand_exact"><int name="Vans">20</int></lst></lst></lst>
</response>


<?xml version="1.0" ?>
<!--
 Licensed to the Apache Software Foundation (ASF) under one or more
 contributor license agreements.  See the NOTICE file distributed with
 this work for additional information regarding copyright ownership.
 The ASF licenses this file to You under the Apache License, Version 2.0
 (the "License"); you may not use this file except in compliance with
 the License.  You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.
-->

<!-- This is the Solr schema file. This file should be named "schema.xml" and
 should be in the conf directory under the solr home
 (i.e. ./solr/conf/schema.xml by default) 
 or located where the classloader for the Solr webapp can find it.

 For more information, on how to customize this file, please see
 http://wiki.apache.org/solr/SchemaXml
-->

<schema name="zappos" version="1.1">
  <!-- attribute "name" is the name of this schema and is only used for display purposes.
       Applications should change this to reflect the nature of the search collection.
       version="1.1" is Solr's version number for the schema syntax and semantics.  It should
       not normally be changed by applications.
       1.0: multiValued attribute did not exist, all fields are multiValued by nature
       1.1: multiValued attribute introduced, false by default -->

  <types>
    <!-- field type definitions. The "name" attribute is
       just a label to be used by field definitions.  The "class"
       attribute and any other attributes determine the real
       behavior of the fieldtype.
         Class names starting with "solr" refer to java classes in the
       org.apache.solr.analysis package.
    -->

    <!-- The StrField type is not analyzed, but indexed/stored verbatim.  
       - StrField and TextField support an optional compressThreshold which
       limits compression (if enabled in the derived fields) to values which
       exceed a certain size (in characters).
    -->
    <fieldtype name="string" class="solr.StrField" sortMissingLast="true" omitNorms="true"/>

    <!-- boolean type: "true" or "false" -->
    <fieldtype name="boolean" class="solr.BoolField" sortMissingLast="true" omitNorms="true"/>

    <!-- The optional sortMissingLast and sortMissingFirst attributes are
         currently supported on types that are sorted internally as strings.
       - If sortMissingLast="true", then a sort on this field will cause documents
         without the field to come after documents with the field,
         regardless of the requested sort order (asc or desc).
       - If sortMissingFirst="true", then a sort on this field will cause documents
         without the field to come before documents with the field,
         regardless of the requested sort order.
       - If sortMissingLast="false" and sortMissingFirst="false" (the default),
         then default lucene sorting will be used which places docs without the
         field first in an ascending sort and last in a descending sort.
    -->    


    <!-- numeric field types that store and index the text
         value verbatim (and hence don't support range queries, since the
         lexicographic ordering isn't equal to the numeric ordering) -->
    <fieldtype name="integer" class="solr.IntField" omitNorms="true"/>
    <fieldtype name="long" class="solr.LongField" omitNorms="true"/>
    <fieldtype name="float" class="solr.FloatField" omitNorms="true"/>
    <fieldtype name="double" class="solr.DoubleField" omitNorms="true"/>


    <!-- Numeric field types that manipulate the value into
         a string value that isn't human-readable in its internal form,
         but with a lexicographic ordering the same as the numeric ordering,
         so that range queries work correctly. -->
    <fieldtype name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
    <fieldtype name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
    <fieldtype name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
    <fieldtype name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>


    <!-- The format for this date field is of the form 1995-12-31T23:59:59Z, and
         is a more restricted form of the canonical representation of dateTime
         http://www.w3.org/TR/xmlschema-2/#dateTime    
         The trailing "Z" designates UTC time and is mandatory.
         Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z
         All other components are mandatory.

         Expressions can also be used to denote calculations that should be
         performed relative to "NOW" to determine the value, ie...

               NOW/HOUR
                  ... Round to the start of the current hour
               NOW-1DAY
                  ... Exactly 1 day prior to now
               NOW/DAY+6MONTHS+3DAYS
                  ... 6 months and 3 days in the future from the start of
                      the current day
                      
         Consult the DateField javadocs for more information.
      -->
    <fieldtype name="date" class="solr.DateField" sortMissingLast="true" omitNorms="true"/>

    <!-- solr.TextField allows the specification of custom text analyzers
         specified as a tokenizer and a list of token filters. Different
         analyzers may be specified for indexing and querying.

         The optional positionIncrementGap puts space between multiple fields of
         this type on the same document, with the purpose of preventing false phrase
         matching across fields.

         For more info on customizing your analyzer chain, please see
         http://wiki.apache.org/solr/AnalyzersTokenizersTokenFilters
     -->

    <!-- One can also specify an existing Analyzer class that has a
         default constructor via the class attribute on the analyzer element
    <fieldtype name="text_greek" class="solr.TextField">
      <analyzer class="org.apache.lucene.analysis.el.GreekAnalyzer"/>
    </fieldType>
    -->

    <!-- A text field that only splits on whitespace for exact matching of words -->
    <fieldtype name="text_ws" class="solr.TextField" positionIncrementGap="100">
      <analyzer>
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
      </analyzer>
    </fieldtype>

    <!-- A text field that uses WordDelimiterFilter to enable splitting and matching of
        words on case-change, alpha numeric boundaries, and non-alphanumeric chars,
        so that a query of "wifi" or "wi fi" could match a document containing "Wi-Fi".
        Synonyms and stopwords are customized by external files, and stemming is enabled.
        Duplicate tokens at the same position (which may result from Stemmed Synonyms or
        WordDelim parts) are removed.
        -->
    <fieldtype name="text" class="solr.TextField" positionIncrementGap="100">
      <analyzer type="index">
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
        <!-- in this example, we will only use synonyms at query time
        <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="false"/>
        -->
        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0"/>
        <filter class="solr.LowerCaseFilterFactory"/>
        <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
      </analyzer>
      <analyzer type="query">
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
        <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0"/>
        <filter class="solr.LowerCaseFilterFactory"/>
        <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
      </analyzer>
    </fieldtype>


    <!-- Less flexible matching, but less false matches.  Probably not ideal for product names,
         but may be good for SKUs.  Can insert dashes in the wrong place and still match. -->
    <fieldtype name="textTight" class="solr.TextField" positionIncrementGap="100" >
      <analyzer>
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
        <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="false"/>
        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="0" catenateWords="1" catenateNumbers="1" catenateAll="0"/>
        <filter class="solr.LowerCaseFilterFactory"/>
        <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
      </analyzer>
    </fieldtype>

 </types>


 <fields>
   <!-- Valid attributes for fields:
     name: mandatory - the name for the field
     type: mandatory - the name of a previously defined type from the <types> section
     indexed: true if this field should be indexed (searchable or sortable)
     stored: true if this field should be retrievable
     compressed: [false] if this field should be stored using gzip compression
       (this will only apply if the field type is compressable; among
       the standard field types, only TextField and StrField are)
     multiValued: true if this field may contain multiple values per document
     omitNorms: (expert) set to true to omit the norms associated with
       this field (this disables length normalization and index-time
       boosting for the field, and saves some memory).  Only full-text
       fields or fields that need an index-time boost need norms.
   -->

   <field name="product_id" type="integer" indexed="true" stored="true"/>
   <field name="brand_id" type="integer" indexed="true" stored="true"/>
   <field name="style_id" type="integer" indexed="true" stored="true"/>
   <field name="name" type="text" indexed="true" stored="true"/>
   <field name="brand" type="text" indexed="true" stored="true"/>
   <field name="color" type="text" indexed="true" stored="true" multiValued="true" />
   <field name="product_type" type="text" indexed="true" stored="true" multiValued="true" omitNorms="true"/>
   <field name="description" type="text" indexed="true" stored="true" />
   <field name="thumbnail_url" type="text" indexed="true" stored="true" />
   <field name="product_url" type="text" indexed="true" stored="true" />
   <field name="size" type="text" indexed="true" stored="true" multiValued="true" />
   <field name="width" type="text" indexed="true" stored="true" multiValued="true" />
   <field name="country_code" type="text" indexed="true" stored="true" multiValued="true" />
   <field name="create_date" type="date" indexed="true" stored="true" />

   <field name="price"  type="sfloat" indexed="true" stored="true"/>
   <field name="inStock" type="boolean" indexed="true" stored="true"/>

   <!-- catchall field, containing all other searchable text fields (implemented
        via copyField further on in this schema  -->
   <field name="text" type="text" indexed="true" stored="false" multiValued="true"/>

   <!-- non-tokenized version of manufacturer to make it easier to sort or group
        results by manufacturer.  copied from "manu" via copyField -->
   <field name="brand_exact" type="string" indexed="true" stored="false"/>


   <!-- Dynamic field definitions.  If a field name is not found, dynamicFields
        will be used if the name matches any of the patterns.
        RESTRICTION: the glob-like pattern in the name attribute must have
        a "*" only at the start or the end.
        EXAMPLE:  name="*_i" will match any field ending in _i (like myid_i, z_i)
        Longer patterns will be matched first.  if equal size patterns
        both match, the first appearing in the schema will be used.  -->
   <dynamicField name="*_i"  type="sint"    indexed="true"  stored="true"/>
   <dynamicField name="*_s"  type="string"  indexed="true"  stored="true"/>
   <dynamicField name="*_l"  type="slong"   indexed="true"  stored="true"/>
   <dynamicField name="*_t"  type="text"    indexed="true"  stored="true"/>
   <dynamicField name="*_b"  type="boolean" indexed="true"  stored="true"/>
   <dynamicField name="*_f"  type="sfloat"  indexed="true"  stored="true"/>
   <dynamicField name="*_d"  type="sdouble" indexed="true"  stored="true"/>
   <dynamicField name="*_dt" type="date"    indexed="true"  stored="true"/>
 </fields>

 <!-- field to use to determine and enforce document uniqueness. -->
 <uniqueKey>style_id</uniqueKey>

 <!-- field for the QueryParser to use when an explicit fieldname is absent -->
 <defaultSearchField>description</defaultSearchField>

 <!-- SolrQueryParser configuration: defaultOperator="AND|OR" -->
 <solrQueryParser defaultOperator="OR"/>

  <!-- copyField commands copy one field to another at the time a document
        is added to the index.  It's used either to index the same field differently,
        or to add multiple fields to the same field for easier/faster searching.  -->

   <copyField source="product_type" dest="text"/>
   <copyField source="name" dest="text"/>
   <copyField source="brand" dest="text"/>
   <copyField source="color" dest="text"/>
   <copyField source="description" dest="text"/>

   <copyField source="brand" dest="brand_exact"/>

 <!-- Similarity is the scoring routine for each document vs. a query.
      A custom similarity may be specified here, but the default is fine
      for most applications.  -->
  <similarity class="org.apache.lucene.search.DefaultSimilarity"/>

</schema>

Reply via email to