Bug #8704 warn if CREATE ... UNION is used on a non merge table

Submitted: 22 Feb 2005 18:22 Modified: 4 Feb 2009 9:47
Reporter: Martin Friebe (Gold Quality Contributor) (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: DDL Severity:S4 (Feature request)
Version:4.1.10, 5.1 OS:Any (*)
Assigned to: CPU Architecture:Any
Tags: qc

[22 Feb 2005 18:22] Martin Friebe
Description:
the UNION clause in create table, is only usefull, if used on a merge table. otherwhise its ingnored.

mysql should issue a warning, if ignoring this.

Also, not sure, but I the documentation does not mention that UNION=(), can be used without "=" too

How to repeat:
create table t1 (a int);
Query OK, 0 rows affected (0.00 sec)

create table mrg (a int) union (t1);
Query OK, 0 rows affected (0.00 sec)

show warnings;
Empty set (0.02 sec)

create table mrgb (a int) union=(t1);
Query OK, 0 rows affected (0.00 sec)

show warnings;
Empty set (0.00 sec)

Suggested fix:
add warning
[4 Feb 2009 9:47] Susanne Ebrecht
Many thanks for writing a feature request.

This also is actual for MySQL 5.1.

Our development will discuss this feature request.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.059 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.