List:General Discussion« Previous MessageNext Message »
From:Santeri Paavolainen Date:January 23 2001 10:51am
Subject:3.22 database on 3.23 with field names 'when' will causes errors
View as plain text  
>Description:
	Using database created in 3.22 with a field named 'when'
	causes errors. For example,
		SELECT when FROM atable;
	will fail on syntax error. This works:
		SELECT a.when FROM atable a;
	However, since it's not (apparently) possible to give table
	aliases for inserts, the following will fail with no
	work-around (using aliases):
		INSERT INTO atable (when) values ('2000-1-1');
	Worst of all, ALTER TABLE will not work either:
		ALTER TABLE atable CHANGE when when_done DATE NOT
		NULL;
	will fail!
>How-To-Repeat:
	Create database in 3.22 with a field named 'when', run the
	3.22 database with 3.23 mysqld.
>Fix:
	SELECTs can be worked around with table aliases, others not.

>Submitter-Id:	<submitter ID>
>Originator:	Santeri Paavolainen
>Organization:
  santtu@stripped                    I have become death, destroyer of the worlds.
>
>MySQL support: none
>Synopsis:	Field named 'when' causes errors.
>Severity:	serious
>Priority:	
>Category:	mysql
>Class:		sw-bug
>Release:	mysql-3.23.32 (Official MySQL RPM)

>Environment:
System: Linux kellari 2.4.0 #2 Mon Jan 15 20:58:48 EET 2001 i686 unknown
Architecture: i686

Some paths:  /usr/bin/perl /usr/bin/make /usr/bin/gmake /usr/bin/gcc /usr/bin/cc
GCC: Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.0)
Compilation info: CC='egcs'  CFLAGS='-O6 -fomit-frame-pointer -mpentium'  CXX='egcs' 
CXXFLAGS='-O6 -fomit-frame-pointer 	          -felide-constructors -fno-exceptions
-fno-rtti -mpentium'  LDFLAGS=''
LIBC:
lrwxrwxrwx    1 root     root           11 Jan 15 14:21 /lib/libc.so.6 -> libc-2.2.so
-rwxr-xr-x    1 root     root      5155229 Jan 11 02:09 /lib/libc-2.2.so
-rw-r--r--    1 root     root     24498288 Jan 11 01:35 /usr/lib/libc.a
-rw-r--r--    1 root     root          178 Jan 11 01:35 /usr/lib/libc.so
Configure command: ./configure  --disable-shared --with-mysqld-ldflags=-all-static
--with-client-ldflags=-all-static --enable-assembler --with-mysqld-user=mysql
--with-unix-socket-path=/var/lib/mysql/mysql.sock --prefix=/
--with-extra-charsets=complex --exec-prefix=/usr --libexecdir=/usr/sbin --sysconfdir=/etc
--datadir=/usr/share --localstatedir=/var/lib/mysql --infodir=/usr/info
--includedir=/usr/include --mandir=/usr/man --without-berkeley-db
'--with-comment=Official MySQL RPM'
Thread
3.22 database on 3.23 with field names 'when' will causes errorsSanteri Paavolainen23 Jan
  • Re: 3.22 database on 3.23 with field names 'when' will causes errorsTomi Junnila23 Jan
  • Re: 3.22 database on 3.23 with field names 'when' will causes errorsTomi Junnila23 Jan
    • Re: 3.22 database on 3.23 with field names 'when' will causes errorsTim Bunce23 Jan