# 6.7.21 SHOW FILL TYPE

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

### Syntax

**SHOW** **FILL** **TYPE** [_file_name_] _dataset_name_ [**,** [_file_name_] _dataset_name_]\* [**BY** **NAME**]\
[_post_processing_option_]\
[_output_redirecting_option_]

### Description

Show (i.e. get) the fill type of an HDF5 dataset named _dataset_name_. Multiple datasets’ fill types can be obtained at once by separating their names with a comma (,). If _dataset_name_ was not found or its fill type could not be obtained (due to unknown/unexpected reasons), no subsequent datasets are checked, and an error is raised.

### Parameter(s)

_file_name_ – optional string that specifies the name of the HDF5 file storing the dataset whose fill type is to be obtained. If _file_name_ is specified, the file is opened on the fly, the fill type of the dataset is obtained, and the file is subsequently closed. If not specified, the file currently in use is used instead.

_dataset_name_ – mandatory string that specifies the name of the HDF5 dataset whose fill type is to be obtained.

_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

If the keyword BY NAME is not specified, it returns the fill type of an HDF5 dataset as an [HDFQL_INT](5-1-constants.md#hdfql_int), which can be [HDFQL_FILL_DEFAULT](5-1-constants.md#hdfql_fill_default), [HDFQL_FILL_DEFINED](5-1-constants.md#hdfql_fill_defined), [HDFQL_FILL_UNDEFINED](5-1-constants.md#hdfql_fill_undefined), or [HDFQL_FILL_NEVER](5-1-constants.md#hdfql_fill_never) depending on whether the fill is default, (user) defined, undefined, or never, respectively. Otherwise, if the keyword BY NAME is specified, it returns the fill type of a dataset as an [HDFQL_VARCHAR](5-1-constants.md#hdfql_varchar), which can be “FILL_DEFAULT”, “FILL_DEFINED”, “FILL_UNDEFINED”, or “FILL_NEVER”.

### Example(s)

```hdfql
# create an HDF5 dataset named "my_dataset0" of data type int 
CREATE DATASET my_dataset0 AS INT

# show (i.e. get) fill type of dataset "my_dataset0" (should return 1 (i.e. HDFQL_FILL_DEFAULT))
SHOW FILL TYPE my_dataset0

# create an HDF5 dataset named "my_dataset1" of data type int with a fill value of 20 
CREATE DATASET my_dataset1 AS INT FILL(20)

# show (i.e. get) fill type of dataset "my_dataset1" (should return 2 (i.e. HDFQL_FILL_DEFINED))
SHOW FILL TYPE my_dataset1

# create an HDF5 dataset named "my_dataset2" of data type variable-length char of one dimension (size 5) with an undefined fill value
CREATE DATASET my_dataset2 AS VARCHAR(5) FILL UNDEFINED

# show (i.e. get) fill type of dataset "my_dataset2" (should return 4 (i.e. HDFQL_FILL_UNDEFINED))
SHOW FILL TYPE my_dataset2
```
