zeroflag commented on a change in pull request #1633:
URL: https://github.com/apache/hive/pull/1633#discussion_r528663216
##########
File path: hplsql/src/main/java/org/apache/hive/hplsql/Copy.java
##########
@@ -233,16 +219,16 @@ void copyToFile(HplsqlParser.Copy_stmtContext ctx, Query
query) throws Exception
sql = "INSERT INTO " + sqlInsertName + " VALUES (";
rowdel = ");\n".getBytes();
}
- while (rs.next()) {
+ while (query.next()) {
if (sqlInsert) {
out.write(sql.getBytes());
}
- for (int i = 1; i <= cols; i++) {
- if (i > 1) {
+ for (int i = 0; i < cols; i++) {
Review comment:
I supposed to be 0 based everywhere.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]