Access sql with python, please. I'm desperate

Alex Martelli aleax at aleax.it
Fri Nov 14 04:51:30 EST 2003


sdd wrote:

> I wrote:
>> That said, on at least some systems you can say:
>> 
>>    SELECT * for (SELECT age, weight FROM personnel)
>>    WHERE age in (SELECT age FROM retirees)
> When of course I meant to write:
>     SELECT * FROM (SELECT age, weight FROM personnel)
>     WHERE age IN (SELECT age FROM retirees)

Yes, any "true" relational DB supports nested queries
(has mySQL gotten around to that yet...?), but I'm not
sure why you want the FIRST of the two nestings here --
why not just one nesting, as in:

SELECT age, weight FROM personnel
WHERE age in (SELECT age FROM retirees)

?


Alex





More information about the Python-list mailing list