Hi, I wanna to import many tables from MySQL. Assume that, I have two tables: *** Tables 1: tbl_tableA(id, nameA) with data (1, A1), (2, A2), (3, A3). *** Tables 2: tbl_tableB(id, nameB) with data (1, B1), (2, B2), (3, B3), (4, B4), (5, B5).
I configure: <dataConfig> <dataSource type="JdbcDataSource" driver="com.mysql.jdbc.Driver" url="jdbc:mysql://xxxxxx" user="xxx" password="xxx" batchSize="1" /> <document name = "atexpats6"> <entity name="tableA" query="select * from tbl_tableA"> <field name="id" column="id"/> <field name="nameA" column="nameA" /> </entity> <entity name="tableB" query="select * from tbl_tableB"> <field name="id" column="id"/> <field name="nameA" column="nameA" /> </entity> </document> </dataConfig> I define nameA, nameB in schema.xml and id is configured by <uniqueKey>id</uniqueKey> When I import data by http://localhost:8983/solr/dataimport?command=full-import It's successfull. But only data of tbl_tableB had indexed. I think because <id> is unique. When importing tbl_tableA import first, tbl_tableB import after. tbl_tableB has id which the same id in tableA, so only data of tableB had indexed with unique id. Anyone can help me to configure data import handler that can index all data of two (more) tables which have the same id in each table. Thanks. ----- Phat T. Dong -- View this message in context: http://lucene.472066.n3.nabble.com/Data-import-handler-with-multi-tables-tp4098026.html Sent from the Solr - User mailing list archive at Nabble.com.