> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wherobots.com/llms.txt
> Use this file to discover all available pages before exploring further.

# RS_BandNoDataValue

Returns the no data value of the given band of the given raster. If no band is given, band 1 is assumed. The band parameter is 1-indexed. If there is no data value associated with the given band, RS\_BandNoDataValue returns null.

<Note>
  If the given band does not lie in the raster, RS\_BandNoDataValue throws an IllegalArgumentException
</Note>

## Signatures

```sql theme={"system"}
RS_BandNoDataValue (raster: Raster, band: Integer = 1)
```

## Parameters

<ParamField body="raster" type="Raster" required>
  The input raster.
</ParamField>

<ParamField body="band" type="Integer" required default="1">
  The band index.
</ParamField>

## Return type

<ResponseField type="Double">
  A numeric value.
</ResponseField>

## Examples

```sql theme={"system"}
SELECT RS_BandNoDataValue(raster, 1) from rasters;
```

```
0.0
```

```sql theme={"system"}
SELECT RS_BandNoDataValue(raster) from rasters_without_nodata;
```

```
null
```

```sql theme={"system"}
SELECT RS_BandNoDataValue(raster, 3) from rasters;
```

```
IllegalArgumentException: Provided band index 3 is not present in the raster.
```
