1
votes

I'm having issues figuring out exactly how to import blob data from a SQL Server database into SOLR. This is hooked into NAV as well. I've managed to get the data out of the table within NAV, however I need this data in SOLR for search purposes.

Here's my current dataConfig file.

<dataConfig>
    <dataSource name="dastream" type="FieldStreamDataSource" />
    <dataSource name="db" driver="com.microsoft.sqlserver.jdbc.SQLServerDriver" url="jdbc:sqlserver://localhost;databaseName=TestingDB" user="sa" password="*******" />
    <document name="items">
        <entity name="item"  query="select [No_], [Desc_ English] as desceng from [Foo$Item]" dataSource="db">
            <field column="No_" name="id" />

            <entity processor="TikaEntityProcessor" url="desceng" dataField="item.desceng" name="blob" dataSource="dastream" format="text" >
                <field column="text" name="desceng"  />
            </entity>
        </entity>

    </document>

</dataConfig>

The error I keep getting is:


Full Import failed:java.lang.RuntimeException: java.lang.RuntimeException: org.apache.solr.handler.dataimport.DataImportHandlerException: java.lang.RuntimeException: unsupported type : class java.lang.String


I'm not sure what I'm missing.

1

1 Answers

1
votes

Maybe this is because Nav stores blobs in his own way. See this question. There ia an example how to extract data using python.