-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added test for query on hierarchical CTE tables.
- Loading branch information
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
Tests/CSQLQueryExpress.Tests/UnitTests/SelectStatements/TestStatement11.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
WITH _t0 AS | ||
( | ||
SELECT | ||
_t0.* | ||
FROM [dbo].[Categories] AS _t0 | ||
), | ||
_t1 AS | ||
( | ||
SELECT | ||
_t1.* | ||
FROM [dbo].[Products] AS _t1 | ||
INNER JOIN _t0 ON (_t1.[CategoryID] = _t0.[CategoryID]) | ||
WHERE (_t1.[SupplierID] IS NOT NULL) | ||
) | ||
|
||
SELECT | ||
_t2.* | ||
FROM [dbo].[Suppliers] AS _t2 | ||
INNER JOIN _t1 ON (_t2.[SupplierID] = _t1.[SupplierID]) |