Bug #10805 inline views not working
Submitted: 23 May 2005 17:17 Modified: 31 May 2005 14:35
Reporter: Phil Collins Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Query Browser Severity:S3 (Non-critical)
Version:1.1.9 OS:Windows (WinXP)
Assigned to: Vladimir Kolesnikov CPU Architecture:Any

[23 May 2005 17:17] Phil Collins
Description:
Error: Column 'id' in field list is ambiguous

How to repeat:
Steps to reproduce (use mysql command line client):
1) mysql> create table foo (id integer primary key, name varchar(10));
2) mysql> insert into foo (name) values ('test');
3) mysql> select foo.name from foo, (select id, name from foo) as foo2 where foo.id = foo2.id
Notice step 3 returns results. Now try and execute SQL from step 3 in the query browser and you get the "Column 'id' in field list is ambiguous" error.

I also tried this SQL with SQL-92 join syntax and had the same results.

Suggested fix:
Looks like the query browser doesn't know how to inspect SQL with inline views. I'm not qualified to suggest a code fix.
[24 May 2005 5:38] MySQL Verification Team
Verified with QB 1.1.9.
Thank you for the bug report.
[31 May 2005 14:35] Vladimir Kolesnikov
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html