change getSchemas method

This commit is contained in:
zyyang 2021-01-21 14:19:20 +08:00
parent 6f6c1f9cd6
commit 851a0b64ac
2 changed files with 3 additions and 9 deletions

View File

@ -493,11 +493,10 @@ public abstract class AbstractDatabaseMetaData implements DatabaseMetaData, Wrap
return null; return null;
} }
public abstract ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, String[] types) public abstract ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, String[] types) throws SQLException;
throws SQLException;
public ResultSet getSchemas() throws SQLException { public ResultSet getSchemas() throws SQLException {
return null; return getEmptyResultSet();
} }
public abstract ResultSet getCatalogs() throws SQLException; public abstract ResultSet getCatalogs() throws SQLException;
@ -753,7 +752,7 @@ public abstract class AbstractDatabaseMetaData implements DatabaseMetaData, Wrap
} }
public ResultSet getSchemas(String catalog, String schemaPattern) throws SQLException { public ResultSet getSchemas(String catalog, String schemaPattern) throws SQLException {
return null; return getEmptyResultSet();
} }
public boolean supportsStoredFunctionsUsingCallSyntax() throws SQLException { public boolean supportsStoredFunctionsUsingCallSyntax() throws SQLException {

View File

@ -914,11 +914,6 @@ public class TSDBDatabaseMetaDataTest {
Assert.assertNull(metaData.getRowIdLifetime()); Assert.assertNull(metaData.getRowIdLifetime());
} }
@Test
public void testGetSchemas() throws SQLException {
Assert.assertNull(metaData.getSchemas());
}
@Test @Test
public void supportsStoredFunctionsUsingCallSyntax() throws SQLException { public void supportsStoredFunctionsUsingCallSyntax() throws SQLException {
Assert.assertFalse(metaData.supportsStoredFunctionsUsingCallSyntax()); Assert.assertFalse(metaData.supportsStoredFunctionsUsingCallSyntax());