use of org.apache.hive.service.cli.operation.GetCrossReferenceOperation in project hive by apache.
the class HiveSessionImpl method getCrossReference.
@Override
public OperationHandle getCrossReference(String primaryCatalog, String primarySchema, String primaryTable, String foreignCatalog, String foreignSchema, String foreignTable) throws HiveSQLException {
acquire(true, true);
OperationManager operationManager = getOperationManager();
GetCrossReferenceOperation operation = operationManager.newGetCrossReferenceOperation(getSession(), primaryCatalog, primarySchema, primaryTable, foreignCatalog, foreignSchema, foreignTable);
OperationHandle opHandle = operation.getHandle();
try {
operation.run();
addOpHandle(opHandle);
return opHandle;
} catch (HiveSQLException e) {
operationManager.closeOperation(opHandle);
throw e;
} finally {
release(true, true);
}
}
Aggregations