You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/dialects/test_tsql.py
+3Lines changed: 3 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1374,6 +1374,9 @@ def test_udf(self):
1374
1374
1375
1375
self.validate_identity("CREATE FUNCTION foo(@bar INTEGER) RETURNS TABLE AS RETURN SELECT 1")
1376
1376
self.validate_identity("CREATE FUNCTION dbo.ISOweek(@DATE DATETIME2) RETURNS INTEGER")
1377
+
self.validate_identity(
1378
+
"CREATE FUNCTION dbo.f() RETURNS TABLE AS RETURN (WITH subquery AS (SELECT id AS id FROM subtable) SELECT other_id FROM main_table AS mt INNER JOIN subquery ON subquery.id = mt.other_id)"
1379
+
)
1377
1380
1378
1381
# The following two cases don't necessarily correspond to valid TSQL, but they are used to verify
1379
1382
# that the syntax RETURNS @return_variable TABLE <table_type_definition> ... is parsed correctly.
0 commit comments