phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maryann Xue (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (PHOENIX-3581) Class-cast exceptions caused by TestUtil.getSplits() and TestUtil.getGuidePostsList()
Date Mon, 09 Jan 2017 19:45:58 GMT

     [ https://issues.apache.org/jira/browse/PHOENIX-3581?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Maryann Xue updated PHOENIX-3581:
---------------------------------
    Issue Type: Sub-task  (was: Bug)
        Parent: PHOENIX-3104

> Class-cast exceptions caused by TestUtil.getSplits() and TestUtil.getGuidePostsList()
> -------------------------------------------------------------------------------------
>
>                 Key: PHOENIX-3581
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-3581
>             Project: Phoenix
>          Issue Type: Sub-task
>            Reporter: Maryann Xue
>            Assignee: Maryann Xue
>            Priority: Minor
>              Labels: calcite
>
> These test utility methods are trying to convert a PrepareStatement object initiated
by the current JDBC Connection into a PhoenixPreparedStatement. While we have switched to
Calcite-Phoenix connections for tests, the PreparedStatement created by the connection will
no longer be a PhoenixPreparedStatement object, so we need to get the original PhoenixConnection
object for such util methods.
> {code}
>         String query = "SELECT /*+ NO_INDEX */ COUNT(*) FROM " + tableName + whereClause;
>         PhoenixPreparedStatement pstmt = conn.prepareStatement(query).unwrap(PhoenixPreparedStatement.class);
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message