[ https://issues.apache.org/jira/browse/PHOENIX-4201?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16163663#comment-16163663 ]
James Taylor commented on PHOENIX-4201: --------------------------------------- [~samarthjain] - it'd be best to clear the client side and server side cache after deleting the metadata here, as soon we'll rely on the cache sometimes when we service these metadata API calls. {code} + @Before + // We need to clean up phoenix metadata to ensure tests don't step on each other + public void deleteMetadata() throws Exception { + try (Connection conn = DriverManager.getConnection(getUrl())) { + String delete = + "DELETE FROM SYSTEM.CATALOG WHERE TABLE_SCHEM IS NULL OR TABLE_SCHEM = '' OR TABLE_SCHEM != 'SYSTEM'"; + conn.createStatement().executeUpdate(delete); + conn.commit(); + delete = "DELETE FROM \"SYSTEM\".\"SEQUENCE\""; + conn.createStatement().executeUpdate(delete); + conn.commit(); + } + } {code} > Remove usage of SCN from QueryDatabaseMetadataIT > ------------------------------------------------ > > Key: PHOENIX-4201 > URL: https://issues.apache.org/jira/browse/PHOENIX-4201 > Project: Phoenix > Issue Type: Bug > Reporter: Samarth Jain > Assignee: Samarth Jain > Attachments: PHOENIX-4201.patch > > -- This message was sent by Atlassian JIRA (v6.4.14#64029)