/** * {@inheritDoc} */ @Override public ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, String[] types) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.TABLES, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(schemaPattern).setTable(tableNamePattern) .setTableTypes(types != null ? Arrays.asList(types) : null)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getIndexInfo(String catalog, String schema, String table, boolean unique, boolean approximate) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getIndexInfo(new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table), unique, approximate); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getImportedKeys(String catalog, String schema, String table) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.IMPORTEDKEYS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
unsetTable(); } else { setTable((String)value);
/** * {@inheritDoc} */ @Override public ResultSet getBestRowIdentifier(String catalog, String schema, String table, int scope, boolean nullable) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getBestRowIdentifier(new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table), scope, nullable); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getExportedKeys(String catalog, String schema, String table) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.EXPORTEDKEYS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getVersionColumns(String catalog, String schema, String table) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.VERSIONCOLUMNS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getPrimaryKeys(String catalog, String schema, String table) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.PRIMARYKEYS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getSuperTables(String catalog, String schemaPattern, String tableNamePattern) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.SUPERTABLES, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(schemaPattern).setTable(tableNamePattern)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getTablePrivileges(String catalog, String schemaPattern, String tableNamePattern) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.TABLEPRIVILEGES, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(schemaPattern).setTable(tableNamePattern)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
public ResultSet getPseudoColumns(String catalog, String schemaPattern, String tableNamePattern, String columnNamePattern) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.PSEUDOCOLUMNS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(schemaPattern).setTable(tableNamePattern) .setColumnName(columnNamePattern)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } } }
/** * {@inheritDoc} */ @Override public ResultSet getColumnPrivileges(String catalog, String schema, String table, String columnNamePattern) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.COLUMNPRIVILEGES, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE).setSchema(schema) .setTable(table).setColumnName(columnNamePattern)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getColumns(String catalog, String schemaPattern, String tableNamePattern, String columnNamePattern) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.COLUMNS, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(schemaPattern).setTable(tableNamePattern) .setColumnName(columnNamePattern)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }
/** * {@inheritDoc} */ @Override public ResultSet getCrossReference(String parentCatalog, String parentSchema, String parentTable, String foreignCatalog, String foreignSchema, String foreignTable) throws SQLException { this.conn.lock(); try { RowSet rs = this.service.getSchemaMetaData( ServiceMetaDataCall.CROSSREFERENCE, new ServiceMetaDataArgs() .setDriverType(ClientConfiguration.DRIVER_TYPE) .setSchema(parentSchema).setTable(parentTable) .setForeignSchema(foreignSchema).setForeignTable(foreignTable)); return new ClientResultSet(this.conn, this.metaAttrs, rs); } catch (SnappyException se) { throw ThriftExceptionUtil.newSQLException(se); } finally { this.conn.unlock(); } }