4 ms·
The normal SQL way is with a recursive CTE and help from the query optimizer. Differs more in feeling (constructing relations with joins vs. defining predicates
by HelloNurse 6y ago
The normal SQL way is with a recursive CTE and help from the query optimizer.
Differs more in feeling (constructing relations with joins vs. defining predicates with logic) than in substance from the Datalog way.
Sqlite official examples: https://sqlite.org/lang_with.html https://sqlite.org/lang_with.html
MySql official examples: https://docs.oracle.com/cd/E17952_01/mysql-8.0-en/with.html https://docs.oracle.com/cd/E17952_01/mysql-8.0-en/with.html