mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Patch for netBSD
Added warning for tables where the auto_increment key is 0 Fixed DELETE ... LIMIT 0 Fixed UPDATE ..LIMIT 0
This commit is contained in:
@@ -170,12 +170,13 @@ int mysql_delete(THD *thd,TABLE_LIST *table_list,COND *conds,ha_rows limit,
|
||||
select=make_select(table,0,0,conds,&error);
|
||||
if (error)
|
||||
DBUG_RETURN(-1);
|
||||
if (select && select->check_quick(test(thd->options & SQL_SAFE_UPDATES),
|
||||
limit))
|
||||
if ((select && select->check_quick(test(thd->options & SQL_SAFE_UPDATES),
|
||||
limit)) ||
|
||||
!limit)
|
||||
{
|
||||
delete select;
|
||||
send_ok(&thd->net,0L);
|
||||
DBUG_RETURN(0);
|
||||
DBUG_RETURN(0); // Nothing to delete
|
||||
}
|
||||
|
||||
/* If running in safe sql mode, don't allow updates without keys */
|
||||
|
||||
Reference in New Issue
Block a user