> ## 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_LogicalOver

Return value from band1 if it's not equal to 0, else return band2 value

## Signatures

```sql theme={"system"}
RS_LogicalOver (Band1: ARRAY[Double], Band2: ARRAY[Double])
```

## Parameters

<ParamField body="Band1" type="ARRAY[Double]" required>
  The first spectral band.
</ParamField>

<ParamField body="Band2" type="ARRAY[Double]" required>
  The second spectral band.
</ParamField>

## Return type

<ResponseField type="Array<Double>">
  An array of double values.
</ResponseField>

## Example

```scala theme={"system"}
val logicalOver = spark.sql("select RS_LogicalOver(band1, band2) as logover from dataframe")
```
