mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
MDEV-17544 No warning when trying to name a primary key constraint.
Warning added.
This commit is contained in:
@ -796,11 +796,15 @@ POINT(1 1)
|
||||
drop function fn3;
|
||||
create table t1(pt POINT);
|
||||
alter table t1 add primary key pti(pt);
|
||||
Warnings:
|
||||
Warning 1280 Name 'pti' ignored for PRIMARY key.
|
||||
drop table t1;
|
||||
create table t1(pt GEOMETRY);
|
||||
alter table t1 add primary key pti(pt);
|
||||
ERROR 42000: BLOB/TEXT column 'pt' used in key specification without a key length
|
||||
alter table t1 add primary key pti(pt(20));
|
||||
Warnings:
|
||||
Warning 1280 Name 'pti' ignored for PRIMARY key.
|
||||
drop table t1;
|
||||
create table t1 select ST_GeomFromText('point(1 1)');
|
||||
desc t1;
|
||||
|
@ -792,11 +792,15 @@ POINT(1 1)
|
||||
drop function fn3;
|
||||
create table t1(pt POINT);
|
||||
alter table t1 add primary key pti(pt);
|
||||
Warnings:
|
||||
Warning 1280 Name 'pti' ignored for PRIMARY key.
|
||||
drop table t1;
|
||||
create table t1(pt GEOMETRY);
|
||||
alter table t1 add primary key pti(pt);
|
||||
ERROR 42000: BLOB/TEXT column 'pt' used in key specification without a key length
|
||||
alter table t1 add primary key pti(pt(20));
|
||||
Warnings:
|
||||
Warning 1280 Name 'pti' ignored for PRIMARY key.
|
||||
drop table t1;
|
||||
create table t1 select ST_GeomFromText('point(1 1)');
|
||||
desc t1;
|
||||
|
Reference in New Issue
Block a user