-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Richard Clarke wrote:
Dan,
    According to http://www.mysql.com/doc/en/News-4.1.0.html

    "SELECT ... FROM DUAL is an alias for SELECT .... (To be compatible with
some other databases)."

Your example does work however.

mysql> select * from ( select 1 ) d;
+---+
| 1 |
+---+
| 1 |
+---+
1 row in set (0.00 sec)

Richard.
The 'dual' syntax is simply re-written to remove the 'from dual' part so you end up with 'select 1'. It's also rather new functionality in 4.1.

I'm pretty sure this logic has not yet been propagated to the code for subqueries. I'm CC'ing the developer responsible for subqueries (Sanja Belkin) on this message so that he is made aware of this issue. It will be important for those moving from Oracle to MySQL or those users used to Oracle-isms :)

Thanks for bringing this issue to our attention! Have a good holiday!

-Mark
- -- MySQL 2003 Users Conference -> http://www.mysql.com/events/uc2003/

For technical support contracts, visit https://order.mysql.com/?ref=mmma

__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Mark Matthews <[EMAIL PROTECTED]>
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, Full-Time Developer - JDBC/Java
/_/ /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
<___/ www.mysql.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.1.90 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE+CML6tvXNTca6JD8RAnsuAJ9lYGc1DQ58m+8bEZHYeYs5Ilh3ZACgn/Ln
kwlop2SgxA9/+KCUqyYn3Sk=
=zFvh
-----END PGP SIGNATURE-----


---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to