[ https://issues.apache.org/jira/browse/PHOENIX-2334?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15141846#comment-15141846 ]
Hudson commented on PHOENIX-2334: --------------------------------- SUCCESS: Integrated in Phoenix-master #1129 (See [https://builds.apache.org/job/Phoenix-master/1129/]) PHOENIX-2334 CSV Bulk load fails on local indexes(Rajeshbabu) (rajeshbabu: rev decbfe3062bbc970050e03fbb198e61a2d30e88c) * phoenix-core/src/main/java/org/apache/phoenix/util/IndexUtil.java * phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java * phoenix-core/src/it/java/org/apache/phoenix/end2end/CsvBulkLoadToolIT.java * phoenix-core/src/main/java/org/apache/phoenix/query/DelegateConnectionQueryServices.java * phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionlessQueryServicesImpl.java * phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java * phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServices.java * phoenix-core/src/main/java/org/apache/phoenix/mapreduce/bulkload/TargetTableRef.java > CSV Bulk load fails on local indexes > ------------------------------------ > > Key: PHOENIX-2334 > URL: https://issues.apache.org/jira/browse/PHOENIX-2334 > Project: Phoenix > Issue Type: Bug > Reporter: maghamravikiran > Assignee: Rajeshbabu Chintaguntla > Fix For: 4.7.0 > > Attachments: PHOENIX-2334.patch, PHOENIX-2334_v2.patch, > PHOENIX-2334_v3.patch > > > CSV Bulk load fails on local indexes. A quick test for this is > {code} > @Test > public void testImportWithLocalIndex() throws Exception { > Statement stmt = conn.createStatement(); > stmt.execute("CREATE TABLE TABLE6 (ID INTEGER NOT NULL PRIMARY KEY, " > + > "FIRST_NAME VARCHAR, LAST_NAME VARCHAR) SPLIt ON (1,2)"); > String ddl = "CREATE LOCAL INDEX TABLE6_IDX ON TABLE6 " > + " (FIRST_NAME ASC)"; > stmt.execute(ddl); > FileSystem fs = FileSystem.get(hbaseTestUtil.getConfiguration()); > FSDataOutputStream outputStream = fs.create(new > Path("/tmp/input3.csv")); > PrintWriter printWriter = new PrintWriter(outputStream); > printWriter.println("1,FirstName 1,LastName 1"); > printWriter.println("2,FirstName 2,LastName 2"); > printWriter.close(); > CsvBulkLoadTool csvBulkLoadTool = new CsvBulkLoadTool(); > csvBulkLoadTool.setConf(hbaseTestUtil.getConfiguration()); > int exitCode = csvBulkLoadTool.run(new String[] { > "--input", "/tmp/input3.csv", > "--table", "table6", > "--zookeeper", zkQuorum}); > assertEquals(0, exitCode); > ResultSet rs = stmt.executeQuery("SELECT id, FIRST_NAME FROM TABLE6 > where first_name='FirstName 2'"); > assertTrue(rs.next()); > assertEquals(2, rs.getInt(1)); > assertEquals("FirstName 2", rs.getString(2)); > rs.close(); > stmt.close(); > } > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)