summaryrefslogtreecommitdiff
path: root/sql/sql_delete.cc
diff options
context:
space:
mode:
authorunknown <monty@hundin.mysql.fi>2001-11-22 14:40:38 +0200
committerunknown <monty@hundin.mysql.fi>2001-11-22 14:40:38 +0200
commite673b6dcf8b55ec4457ab554a1c09ccf3c079463 (patch)
treeed7b5ac619c61e789b26d5243f8391f68a3fa04a /sql/sql_delete.cc
parentd576cd65d00d23b634e0ef4254660e67c055c045 (diff)
parent7ef7d93726929ec678a8b07bed1be7bb56ad4b10 (diff)
downloadmariadb-git-e673b6dcf8b55ec4457ab554a1c09ccf3c079463.tar.gz
merge
BitKeeper/etc/logging_ok: auto-union Docs/manual.texi: Auto merged innobase/srv/srv0srv.c: Auto merged myisam/mi_check.c: Auto merged myisam/mi_open.c: Auto merged myisam/mi_packrec.c: Auto merged myisam/myisamdef.h: Auto merged mysql-test/mysql-test-run.sh: Auto merged mysql-test/t/fulltext.test: Auto merged sql/stacktrace.c: Auto merged sql/mysql_priv.h: Auto merged sql/sql_base.cc: Auto merged sql/sql_update.cc: Auto merged
Diffstat (limited to 'sql/sql_delete.cc')
-rw-r--r--sql/sql_delete.cc15
1 files changed, 6 insertions, 9 deletions
diff --git a/sql/sql_delete.cc b/sql/sql_delete.cc
index a712d4ca54c..464216d56ba 100644
--- a/sql/sql_delete.cc
+++ b/sql/sql_delete.cc
@@ -1,28 +1,24 @@
/* Copyright (C) 2000 MySQL AB
-
+
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-
/*
Delete of records and truncate of tables.
-
Multi-table deletes were introduced by Monty and Sinisa
*/
-
-
#include "mysql_priv.h"
#include "ha_innobase.h"
#include "sql_select.h"
@@ -52,7 +48,7 @@ int mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, ORDER *order,
table->file->info(HA_STATUS_VARIABLE | HA_STATUS_NO_LOCK);
thd->proc_info="init";
table->map=1;
- if (setup_conds(thd,table_list,&conds))
+ if (setup_conds(thd,table_list,&conds) || setup_ftfuncs(thd))
DBUG_RETURN(-1);
/* Test if the user wants to delete all rows */
@@ -79,7 +75,7 @@ int mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, ORDER *order,
if (error)
DBUG_RETURN(-1);
if ((select && select->check_quick(test(thd->options & SQL_SAFE_UPDATES),
- limit)) ||
+ limit)) ||
!limit)
{
delete select;
@@ -129,6 +125,7 @@ int mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, ORDER *order,
}
init_read_record(&info,thd,table,select,1,1);
+ init_ftfuncs(thd,1);
deleted=0L;
thd->proc_info="updating";
while (!(error=info.read_record(&info)) && !thd->killed)