I was trying to find duplicate date entries this way:
CREATE TABLE `galerie` (
`ID` int(5) NOT NULL auto_increment,
`datum` date NOT NULL default '0000-00-00',
`path` varchar(50) collate utf8_czech_ci NOT NULL,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=121 DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci;
select * from galerie x WHERE
(select count(*) from galerie y where y.datum=x.datum)>1
Query returned desired rows.. I clicked delete button on unwanted row. Error was shown:
SQL:
DELETE FROM galerie WHERE x.ID =27 LIMIT 1
MySQL error:
#1054 - Unknown column 'x.ID' in where clause
Logged In: YES
user_id=1383652
Originator: NO
if you delibrately hide the real name of your table by using an alias how can pma possibly know for which table "x" is an alias?
If you don't want the alias in the delete link just don't use an alias:
select * from galerie WHERE
(select count(*) from galerie y where y.datum=galerie.datum)>1
just my 2 cent
Logged In: YES
user_id=1811322
Originator: YES
> how can pma possibly know for which table "x" is an alias?
it should be done by searching sql syntax "tablename alias" | "tablename as alias"... or whatever...
>If you don't want the alias .. don't use an alias..
y, but thats not the solution, why i am submitting nonworking button. Aliases have no place in managing buttons...
Logged In: YES
user_id=210714
Originator: NO
Fixed for 2.10.3.
Logged In: YES
user_id=210714
Originator: NO
Note: fix only applicable for mysqli extension.