[Amazon](500310) Invalid operation error

0

Hi Team,
We are fetching the data from redshift db using JDBC way in java.
The query used for getting the data from tables is select * from table_name limit 200;
Below are the errors occurred for different tables. .I am able to see the data in resultset .But while getting next record of particular row it throwing the below errors. Could you please help us to understand the error and resolution for it.

ERROR1:
[Amazon](500310) Invalid operation: Invalid input syntax for type numeric

Details:
error: Invalid input syntax for type numeric
code: 8001
context: value: ""
query: 88634410
location: cg_util.cpp:604
process: query19_773_88634410 [pid=79398]
-----------------------------------------------;
at com.amazon.redshift.client.messages.inbound.ErrorResponse.toErrorException(Unknown Source)
    at com.amazon.redshift.client.PGMessagingContext.handleErrorResponse(Unknown Source)  
    at com.amazon.redshift.client.PGMessagingContext.handleMessage(Unknown Source)  
    at com.amazon.jdbc.communications.InboundMessagesPipeline.getNextMessageOfClass(Unknown Source)  
    at com.amazon.redshift.dataengine.PGResultSet.hasMoreRows(Unknown Source)  
    at com.amazon.jdbc.common.SForwardResultSet.updateCursorPosition(Unknown Source)  

ERROR2:For other table

[Amazon](500310) Invalid operation: Divide by zero;
at com.amazon.redshift.client.messages.inbound.ErrorResponse.toErrorException(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.handleErrorResponse(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.handleMessage(Unknown Source)
at com.amazon.jdbc.communications.InboundMessagesPipeline.getNextMessageOfClass(Unknown Source)
at com.amazon.redshift.dataengine.PGResultSet.hasMoreRows(Unknown Source)
at com.amazon.jdbc.common.SForwardResultSet.updateCursorPosition(Unknown Source)
at com.amazon.jdbc.common.SForwardResultSet.next(Unknown Source)

ERROR3:
java.sql.SQLException: [Amazon](500310) Invalid operation: operator does not exist: text ||;
at com.amazon.redshift.client.messages.inbound.ErrorResponse.toErrorException(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.handleErrorResponse(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.handleMessage(Unknown Source)
at com.amazon.jdbc.communications.InboundMessagesPipeline.getNextMessageOfClass(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.doMoveToNextClass(Unknown Source)
at com.amazon.redshift.client.PGMessagingContext.getParameterDescription(Unknown Source)
at com.amazon.redshift.client.PGClient.prepareStatement(Unknown Source)
at com.amazon.redshift.dataengine.PGQueryExecutor.<init>(Unknown Source)
at com.amazon.redshift.dataengine.PGDataEngine.prepare(Unknown Source)
at com.amazon.jdbc.common.SPreparedStatement.<init>(Unknown Source)
at com.amazon.jdbc.jdbc41.S41PreparedStatement.<init>(Unknown Source)
at com.amazon.jdbc.jdbc42.S42PreparedStatement.<init>(Unknown Source)
at com.amazon.redshift.core.jdbc42.PGJDBC42PreparedStatement.<init>(Unknown Source)
at com.amazon.redshift.core.jdbc42.PGJDBC42ObjectFactory.createPreparedStatement(Unknown Source)
at com.amazon.jdbc.common.SConnection.prepareStatement(Unknown Source)
at com.amazon.jdbc.common.SConnection.prepareStatement(Unknown Source)

Please share your thoughts on this

Thanks,
Padma Yeddula

已提问 3 年前1578 查看次数
1 回答
0

Are you still having this issue? If so, please provide a minimal code example or script that we can use to reproduce the problem.

You can send me a direct message with this if needed.

已回答 3 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则