2
我已經嘗試的SQL Server,DB2,PostgreSQL和Mysql.Some支持遞歸的基本功能,沒有人支持相互遞歸這樣的:是否有任何數據庫支持相互遞歸查詢
WITH RECURSIVE
x (id) AS (SELECT 1 UNION ALL SELECT id+1 FROM y WHERE id < 5),
y (id) AS (SELECT 1 UNION ALL SELECT id+1 FROM x WHERE id < 5)
SELECT * FROM x;