On Jan 24, 2014, at 11:32 PM, Clemens Ladisch <clem...@ladisch.de> wrote:

> It's exactly the same as "SELECT …", but a little bit easier to write.
> (It behaves like with INSERT, but is now available in every place
> where a SELECT would be allowed.)

Hmmm… seems rather pointless to me.

select 1 as value /* from thin air */ union all
select 2 as value /* from thin air */ 
… etc …

Seems to be good enough. No point in hijacking a totally unrelated construct. I 
would drop such complication if I had a say. There is already a perfectly fine 
construct to conjure constants out of thin air: select. 

> 
>> (2) What about cycles? How does one deal with them?
> 
> With cycles, you probably want to use UNION instead of UNION ALL to
> stop at duplicate records.

Hmmm… not quite sure how this would play out in practice… how would the 
recursion known when to stop?

Say,  given a circular hierarchy such as A-> B -> A…. when does the recursion 
stop?



_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to