Applies to: ✅ Data 360 SQL ✅ Tableau Hyper API
Returns true if at least one input value is true; otherwise returns false.
Syntax
bool_or(<expression>)
Arguments
Required
<expression>: An expression of typeboolean.
Returns
Returns a boolean value. Returns NULL if no rows are selected.
Considerations
- NULL values are ignored in the calculation.
Examples
Check Any True
Check if any order has an issue.
SELECT bool_or(has_issue) AS any_issues
FROM orders
WHERE order_date = '2024-01-15';
Check by Group
Find groups with at least one matching condition.
SELECT category, bool_or(is_featured) AS has_featured_item
FROM products
GROUP BY category;