Skip to content

Commit a8eb123

Browse files
fix static example
1 parent aafdbf4 commit a8eb123

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

sqlmesh/core/macros.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1021,7 +1021,7 @@ def union_if(
10211021
>>> from sqlglot import parse_one
10221022
>>> from sqlglot.schema import MappingSchema
10231023
>>> from sqlmesh.core.macros import MacroEvaluator
1024-
>>> sql = "@UNION_IF(@start_ts = '2025-01-01 00:00:00', 'distinct', foo, bar)"
1024+
>>> sql = "@UNION_IF(True, 'distinct', foo, bar)"
10251025
>>> MacroEvaluator(schema=MappingSchema({"foo": {"a": "int", "b": "string", "c": "string"}, "bar": {"c": "string", "a": "int", "b": "int"}})).transform(parse_one(sql)).sql()
10261026
'SELECT CAST(a AS INT) AS a, CAST(c AS TEXT) AS c FROM foo UNION SELECT CAST(a AS INT) AS a, CAST(c AS TEXT) AS c FROM bar'
10271027
"""

0 commit comments

Comments
 (0)