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

Hi all,

I refactored out List<String>* from the parser for the field names in
the USING clause in favor of a std::list<std::string>.  After the
refactoring, I'm failing this test snippet:

create table t1 (a int,b int);
create table t2 (a int,b int);
insert into t1 values (1,10),(2,20),(3,30);
insert into t2 values (1,10);
select * from t1 inner join t2 using (A);

It works fine for MySQL, but not for Drizzle after this changed as,
funnily enough "a" != "A".

MySQL:

mysql> create table t1 (a int,b int);
Query OK, 0 rows affected (0.02 sec)

mysql> create table t2 (a int,b int);
Query OK, 0 rows affected (0.00 sec)

mysql> insert into t1 values (1,10),(2,20),(3,30);
Query OK, 3 rows affected (0.00 sec)
Records: 3  Duplicates: 0  Warnings: 0

mysql> insert into t2 values (1,10);
Query OK, 1 row affected (0.00 sec)

mysql> select * from t1 inner join t2 using (A);
+------+------+------+
| a    | b    | b    |
+------+------+------+
|    1 |   10 |   10 |
+------+------+------+
1 row in set (0.01 sec)

Drizzle after change:

drizzle> create table t1 (a int,b int);
Query OK, 0 rows affected (0 sec)

drizzle> create table t2 (a int,b int);
Query OK, 0 rows affected (0.01 sec)

drizzle> insert into t1 values (1,10),(2,20),(3,30);
Query OK, 3 rows affected (0.01 sec)
Records: 3  Duplicates: 0  Warnings: 0

drizzle> insert into t2 values (1,10);
Query OK, 1 row affected (0 sec)

drizzle> select * from t1 inner join t2 using (A);
ERROR 1054 (42S22): Unknown column 'A' in 'from clause'

Personally, I believe the new Drizzle behaviour should be the correct
one, no?

Am I forgetting some MySQL compatibility mode around lower case field
names or something?

Opinions?  Thanks.

- -Jay
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAknzkjoACgkQ2upbWsB4UtHuegCfWbujqjhfYko43n0e7KSfkLHu
688An2+5HXaKQpHsaU9G+wh2I+4mtSrt
=ojNm
-----END PGP SIGNATURE-----

_______________________________________________
Mailing list: https://launchpad.net/~drizzle-discuss
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~drizzle-discuss
More help   : https://help.launchpad.net/ListHelp

Reply via email to