there is an example given for the same

http://wiki.apache.org/solr/DataImportHandler#head-8edbc7e588d97068aa0a61ed2e3e8e61b43debce



On Wed, May 20, 2009 at 11:35 AM, Jianbin Dai <djian...@yahoo.com> wrote:
>
> Hi All,
> I am new here. Thanks for reading my question.
> I want to use DataImportHandler to index my tons of xml files (7GB total) 
> stored in my local disk. My data-config.xml is attached below. It works fine 
> with one file (abc.xml), but how can I index all xml files at one time? 
> Thanks!
>
>
> <dataConfig>
>        <dataSource type="FileDataSource" />
>        <document>
>                <entity name="example"
>                        url="/root/abc.xml"
>                        processor="XPathEntityProcessor"
>                        forEach="/ShopzillaQueryResponse/product"
>                        transformer="DateFormatTransformer">
>
>                        <field column="id"  
> xpath="/ShopzillaQueryResponse/product/id" />
>                        <field column="name"        
> xpath="/ShopzillaQueryResponse/product/name" />
>                        <field column="sku"         
> xpath="/ShopzillaQueryResponse/product/sku" />
>                        <field column="mydescription"  
> xpath="/ShopzillaQueryResponse/product/desc_short" />
>                        <field column="price"      
> xpath="/ShopzillaQueryResponse/product/merchantListing/merchantProduct/price" 
> />
>
>                </entity>
>        </document>
> </dataConfig>
>
>
>
>
>



-- 
-----------------------------------------------------
Noble Paul | Principal Engineer| AOL | http://aol.com

Reply via email to