Skip to main content
  • lockTable

    public LockTableResponse lockTable(LockTableRequest request) throws GPUdbException
    Manages global access to a table’s data. By default a table has a lockType of READ_WRITE, indicating all operations are permitted. A user may request a READ_ONLY or a WRITE_ONLY lock, after which only read or write operations, respectively, are permitted on the table until the lock is removed. When lockType is NO_ACCESS then no operations are permitted on the table. The lock status can be queried by setting lockType to STATUS.
    Parameters:
    request - Request object containing the parameters for the operation.
    Returns:
    Response object containing the results of the operation.
    Throws:
    GPUdbException - if an error occurs during the operation.
  • lockTable

    public LockTableResponse lockTable(String tableName, String lockType, Map<String,String> options) throws GPUdbException
    Manages global access to a table’s data. By default a table has a lockType of READ_WRITE, indicating all operations are permitted. A user may request a READ_ONLY or a WRITE_ONLY lock, after which only read or write operations, respectively, are permitted on the table until the lock is removed. When lockType is NO_ACCESS then no operations are permitted on the table. The lock status can be queried by setting lockType to STATUS.
    Parameters:
    tableName - Name of the table to be locked, in [schema_name.]table_name format, using standard name resolution rules. It must be a currently existing table or view.
    lockType - The type of lock being applied to the table. Setting it to STATUS will return the current lock status of the table without changing it. Supported values:The default value is STATUS.
    options - Optional parameters. The default value is an empty Map.
    Returns:
    Response object containing the results of the operation.
    Throws:
    GPUdbException - if an error occurs during the operation.