Options

Unexpected message type: DataRow

I'm getting this exception when executing a copy.

 

java.sql.SQLException: [Vertica][VJDBC](100023) Unexpected message type: DataRow.
    at com.vertica.io.ProtocolStream.readExpectedMessage(Unknown Source) ~[vertica-7.1.1-0.jar:na]
    at com.vertica.dataengine.VQueryExecutor.readCopyDataResponse(Unknown Source) ~[vertica-7.1.1-0.jar:na]
    at com.vertica.dataengine.VQueryExecutor.handleExecuteResponse(Unknown Source) ~[vertica-7.1.1-0.jar:na]
    at com.vertica.dataengine.VQueryExecutor.execute(Unknown Source) ~[vertica-7.1.1-0.jar:na]
    at com.vertica.jdbc.VerticaCopyStream.execute(Unknown Source) ~[vertica-7.1.1-0.jar:na]
    at com.foo.MyThing.run(MyThing:java:77) ~[classes/:na]

...

 

The line that's triggering it is the execute() below:

 

copyStream = new VerticaCopyStream(verticaConnection, copyStatement);
copyStream.start();
copyStream.addStream(new ByteArrayInputStream(bytes));
copyStream.execute();

 

I've googled for an explanation and remedy. But I haven't found anything anywhere that even mentions "Unexpected message type: DataRow".

 

Any suggestions?

Comments

  • Options

    Per Vertica JDBC docs <http://my.vertica.com/docs/7.1.x/HTML/Content/JDBC/index.html>:

     

    "This class [VerticaCopyStream] also implements Exceptions and Rejections files where, if specified in the Copy statement, the rejected rows will be written to the file designated as REJECTED DATA and the reason for rejection will be written to the designated EXCEPTIONS file. If these are specified, the driver will return an empty list with any calls to getRejects(). The rejection files will contain more detailed rejection information and can be checked instead."

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file