# 6.7.24 SHOW USERBLOCK SIZE

Part of: [6 Language](6-language.md) › [6.7 Data Introspection Language (DIL)](6-7-data-introspection-language-dil.md)

### Syntax

**SHOW** **USERBLOCK** **SIZE** [_file_name_ [**,** _file_name_]\*]\
[_post_processing_option_]\
[_output_redirecting_option_]

### Description

Show (i.e. get) the size (in bytes) of a user-defined block of data stored within an HDF5 file named _file_name_ or within the HDF5 file currently in use. Multiple files’ user-defined blocks of data sizes can be checked at once by separating their names with a comma (,). If _file_name_ was not found or its user-defined block of data size could not be obtained (due to unknown/unexpected reasons), no subsequent files are checked, and an error is raised.

### Parameter(s)

_file_name_ – optional string that specifies the name of the HDF5 file whose user-defined block of data size (in bytes) is to be obtained. If _file_name_ is specified, the file is opened on the fly, the user-defined block of data size is obtained, and the file is subsequently closed. If not specified, the file currently in use is used instead.

_post_processing_option_ – optional option that transforms the result set according to the programmer’s needs, such as ordering or truncating (please refer to the section [PROCESSING](6-2-processing.md) for additional information).

_output_redirecting_option_ – optional option that specifies the cursor in use, an HDF5 object (i.e. dataset or attribute), a (text, binary, or Excel) file, or memory (i.e. user-defined variable) to write the result set into (please refer to the subsection [INTO](6-3-2-into.md) for additional information). If not specified, the cursor in use is populated with the result set instead (please refer to the chapter [CURSOR](4-cursor.md) for additional information).

### Return

The size (in bytes) of a user-defined block of data stored within an HDF5 file as an [HDFQL_BIGINT](5-1-constants.md#hdfql_bigint).

### Example(s)

```hdfql
# create an HDF5 file named "my_file0.h5" with no user-defined block of data 
CREATE FILE my_file0.h5

# show (i.e. get) size (in bytes) of the user-defined block of data stored within file "my_file0.h5" (should return 0)
SHOW USERBLOCK SIZE my_file0.h5

# create an HDF5 file named "my_file1.h5" with a user-defined block of data (size 512) storing values 50, 60, and 70
CREATE FILE my_file1.h5 USERBLOCK SIZE 512 VALUES(50, 60, 70)

# show (i.e. get) size (in bytes) of the user-defined block of data stored within file "my_file1.h5" (should return 512)
SHOW USERBLOCK SIZE my_file1.h5

# create an HDF5 file named "my_file2.h5" with a user-defined block of data (size 8192) storing values from a binary file named "my_file.pdf"
CREATE FILE my_file2.h5 USERBLOCK SIZE 8192 VALUES FROM BINARY FILE my_file.pdf

# use (i.e. open) HDF5 file "my_file2.h5" 
USE FILE my_file2.h5

# show (i.e. get) size (in bytes) of the user-defined block of data stored within the file currently in use (should return 8192)
SHOW USERBLOCK SIZE
```
