solrj - solr 4.4 multiple datasource connection -
in db-data-config.xml have configured 2 datasource, each parameter name, example:
<datasource name="test1" type="jdbcdatasource" driver="com.mysql.jdbc.driver" url="jdbc:mysql://localhost/firstdb" user="username1" password="psw1"/> <datasource name="test2" type="jdbcdatasource" driver="com.mysql.jdbc.driver" url="jdbc:mysql://localhost/seconddb" user="username2" password="psw2"/> <document name="content"> <entity name="news" datasource="test1" query="select..."> <field column="otype_id" name="otypeid" /> <field column="nws_id" name="cntid" /> .... </entity> <entity name="news_update" datasource="test2" query="select..."> <field column="otype_id" name="otypeid" /> <field column="nws_id" name="cntid" /> .... </entity> </document> </dataconfig>
but when in solr dataimport execute second entity-name-query launch exception:
"table 'firstdb.secondtable' doesn't exist\n\tat" me? thank in advance
a think query news_update wrong. must have error on name of table.
Comments
Post a Comment