3 ms·
FROM ℝ SELECT 1 ? :-)
by rhplus 3y ago
FROM ℝ SELECT 1
? :-)
- hn92726819 3y agoI wonder if there is a concept of infinite length SQL tables. Not sure what would happen with: ORDER DESC COUNT(*) I can't find anything after a quick search except recursive views that must terminate (therefore aren't infinite)
- jasomill 3y agoCOUNT is easy: > SELECT COUNT(*) FROM ℤ; ℵ₀ > SELECT COUNT(*) FROM ℝ; POWER(2,ℵ₀) > EXEC sp_configure 'continuum hypothesis','1'; > RECONFIGURE; > SELECT COUNT(*) FROM ℝ; ℵ₁ While non-termination is probably best left implementation-defined (to allow caller-terminated streams of infinite results where they make sense), ORDER BY would clearly be an error where no well-defined "first" or "next" result exists.
- wlindley 3y agoHow fun it would be to receive a Cantor result in which as many elements from the original set as there were have been removed, leaving a set drawn from what you started with which still contains as many elements!