mariadb/ndb/tools/delete_all.cpp

212 lines
5.4 KiB
C++
Raw Normal View History

/* Copyright (C) 2003 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 */
#include <ndb_global.h>
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
#include <ndb_opts.h>
#include <NdbOut.hpp>
#include <NdbApi.hpp>
#include <NdbSleep.h>
#include <NDBT.hpp>
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
static int clear_table(Ndb* pNdb, const NdbDictionary::Table* pTab, int parallelism=240);
added config parameter Group on connection moved NdbWaiter, m_ndb_cluster_connection, to impl class moved node selection things to cluster connection moved all private things to impl class added opts for shared memory and node selection changed opts handling somewhat; introduced enum for options and common handling of option variables added checks for transporter support automatic addition of shared mem transporters moved wait_until_ready code to cluster connection added control of usage of new node selection method ndb/include/mgmapi/mgmapi_config_parameters.h: added config parameter Group on connection ndb/include/ndbapi/Ndb.hpp: moved NdbWaiter, m_ndb_cluster_connection, to impl class moved node selection things to cluster connection ndb/include/ndbapi/ndb_cluster_connection.hpp: moved all private things to impl class ndb/include/util/ndb_opts.h: added opts for shared memory and node selection ndb/src/kernel/vm/Configuration.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/src/mgmclient/main.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/src/mgmsrv/ConfigInfo.cpp: added checks for transporter support automatic addition of shared mem transporters ndb/src/mgmsrv/MgmtSrvr.cpp: in alloc node id first choose connection with specified hostname ndb/src/mgmsrv/main.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/src/ndbapi/DictCache.hpp: added include file ndb/src/ndbapi/Ndb.cpp: enabled using new node selection method moved wait_until_ready code to cluster connection moved node selection (hint) to cluster connection removed start transaction dgroup ndb/src/ndbapi/NdbDictionaryImpl.hpp: removed and added inclusde files ndb/src/ndbapi/NdbImpl.hpp: moved things from Ndb into Impl class moved waiter things to new file NdbWaiter.hpp ndb/src/ndbapi/NdbScanOperation.cpp: ndbwaiter is no in impl class ndb/src/ndbapi/Ndbif.cpp: ndbwaiter is no in impl class ndb/src/ndbapi/Ndbinit.cpp: moved some Ndb things into impl class ndb/src/ndbapi/TransporterFacade.hpp: changed friend declaration ndb/src/ndbapi/ndb_cluster_connection.cpp: moved node selection things to cluster connection moved things from cluster connection to cluster connection impl class ndb/test/ndbapi/testNdbApi.cpp: removed start transaction dgroup ndb/tools/delete_all.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/desc.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/drop_index.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/drop_tab.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/listTables.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/restore/restore_main.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/select_all.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/select_count.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables ndb/tools/waiter.cpp: changed opts handling somewhat; introduced enum for options and common handling of option variables sql/ha_ndbcluster.cc: added control of usage of new node selection method sql/mysqld.cc: added control of usage of new node selection method
2004-12-20 12:36:14 +01:00
enum ndb_delete_all {
NDB_STD_OPTS_OPTIONS
};
NDB_STD_OPTS_VARS;
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
static const char* _dbname = "TEST_DB";
static struct my_option my_long_options[] =
{
NDB_STD_OPTS("ndb_desc"),
{ "database", 'd', "Name of database table is in",
(gptr*) &_dbname, (gptr*) &_dbname, 0,
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
};
static void print_version()
{
printf("MySQL distrib %s, for %s (%s)\n",MYSQL_SERVER_VERSION,SYSTEM_TYPE,MACHINE_TYPE);
}
static void usage()
{
char desc[] =
"tabname\n"\
"This program will delete all records in the specified table using scan delete.\n";
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
print_version();
my_print_help(my_long_options);
my_print_variables(my_long_options);
}
static my_bool
get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
char *argument)
{
switch (optid) {
case '#':
DBUG_PUSH(argument ? argument : "d:t:O,/tmp/ndb_delete_all.trace");
break;
case 'V':
print_version();
exit(0);
case '?':
usage();
exit(0);
}
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
return 0;
}
int main(int argc, char** argv){
NDB_INIT(argv[0]);
const char *load_default_groups[]= { "mysql_cluster",0 };
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
load_defaults("my",load_default_groups,&argc,&argv);
int ho_error;
if ((ho_error=handle_options(&argc, &argv, my_long_options, get_one_option)))
return NDBT_ProgramExit(NDBT_WRONGARGS);
Ndb_cluster_connection con(opt_connect_str);
if(con.connect(12, 5, 1) != 0)
{
return NDBT_ProgramExit(NDBT_FAILED);
}
Ndb MyNdb(&con, _dbname );
if(MyNdb.init() != 0){
ERR(MyNdb.getNdbError());
return NDBT_ProgramExit(NDBT_FAILED);
}
// Connect to Ndb and wait for it to become ready
while(MyNdb.waitUntilReady() != 0)
ndbout << "Waiting for ndb to become ready..." << endl;
// Check if table exists in db
int res = NDBT_OK;
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
for(int i = 0; i<argc; i++){
const NdbDictionary::Table * pTab = NDBT_Table::discoverTableFromDb(&MyNdb, argv[i]);
if(pTab == NULL){
aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
2004-11-01 14:55:43 +01:00
ndbout << " Table " << argv[i] << " does not exist!" << endl;
return NDBT_ProgramExit(NDBT_WRONGARGS);
}
ndbout << "Deleting all from " << argv[i] << "...";
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
if(clear_table(&MyNdb, pTab) == NDBT_FAILED){
res = NDBT_FAILED;
ndbout << "FAILED" << endl;
}
}
return NDBT_ProgramExit(res);
}
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
int clear_table(Ndb* pNdb, const NdbDictionary::Table* pTab, int parallelism)
{
// Scan all records exclusive and delete
// them one by one
int retryAttempt = 0;
const int retryMax = 10;
int deletedRows = 0;
int check;
NdbTransaction *pTrans;
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
NdbScanOperation *pOp;
NdbError err;
int par = parallelism;
while (true){
restart:
if (retryAttempt++ >= retryMax){
g_info << "ERROR: has retried this operation " << retryAttempt
<< " times, failing!" << endl;
return NDBT_FAILED;
}
pTrans = pNdb->startTransaction();
if (pTrans == NULL) {
err = pNdb->getNdbError();
if (err.status == NdbError::TemporaryError){
ERR(err);
NdbSleep_MilliSleep(50);
continue;
}
goto failed;
}
pOp = pTrans->getNdbScanOperation(pTab->getName());
if (pOp == NULL) {
goto failed;
}
wl2126 - ndb - fix last unhandled part of read_multi_range reading sorted multi_range with several range-scans BitKeeper/deleted/.del-NdbResultSet.hpp~e0042f4c18088ff6: Delete: ndb/include/ndbapi/NdbResultSet.hpp BitKeeper/deleted/.del-NdbResultSet.cpp~84d192cf3f42600d: Delete: ndb/src/ndbapi/NdbResultSet.cpp ndb/include/ndbapi/NdbApi.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbIndexScanOperation.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbScanOperation.hpp: Remove NdbResultSet ndb/src/ndbapi/Makefile.am: Remove NdbResultSet ndb/src/ndbapi/NdbConnection.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbIndexOperation.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbScanOperation.cpp: Remove NdbResultSet ndb/test/include/HugoOperations.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanFunctions.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanInterpretTest.hpp: Remove NdbResultSet ndb/test/ndbapi/bank/Bank.cpp: Remove NdbResultSet ndb/test/ndbapi/bank/BankLoad.cpp: Remove NdbResultSet ndb/test/ndbapi/slow_select.cpp: Remove NdbResultSet ndb/test/ndbapi/testBlobs.cpp: Remove NdbResultSet ndb/test/ndbapi/testDataBuffers.cpp: Remove NdbResultSet ndb/test/ndbapi/testDeadlock.cpp: Remove NdbResultSet ndb/test/ndbapi/testIndex.cpp: Remove NdbResultSet ndb/test/ndbapi/testOIBasic.cpp: Remove NdbResultSet ndb/test/ndbapi/testReadPerf.cpp: Remove NdbResultSet ndb/test/ndbapi/testScan.cpp: Remove NdbResultSet ndb/test/ndbapi/testScanPerf.cpp: Remove NdbResultSet ndb/test/src/HugoOperations.cpp: Remove NdbResultSet ndb/test/src/HugoTransactions.cpp: Remove NdbResultSet ndb/test/src/UtilTransactions.cpp: Remove NdbResultSet ndb/tools/delete_all.cpp: Remove NdbResultSet ndb/tools/select_all.cpp: Remove NdbResultSet ndb/tools/select_count.cpp: Remove NdbResultSet sql/ha_ndbcluster.cc: 1) Fix a = 3 -> a= 3 2) Impl. last part of wl2126 ordered "multi ordered scan"
2004-12-07 15:15:49 +01:00
if( pOp->readTuplesExclusive(par) ) {
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
goto failed;
}
if(pTrans->execute(NoCommit) != 0){
err = pTrans->getNdbError();
if(err.status == NdbError::TemporaryError){
ERR(err);
pNdb->closeTransaction(pTrans);
NdbSleep_MilliSleep(50);
continue;
}
goto failed;
}
wl2126 - ndb - fix last unhandled part of read_multi_range reading sorted multi_range with several range-scans BitKeeper/deleted/.del-NdbResultSet.hpp~e0042f4c18088ff6: Delete: ndb/include/ndbapi/NdbResultSet.hpp BitKeeper/deleted/.del-NdbResultSet.cpp~84d192cf3f42600d: Delete: ndb/src/ndbapi/NdbResultSet.cpp ndb/include/ndbapi/NdbApi.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbIndexScanOperation.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbScanOperation.hpp: Remove NdbResultSet ndb/src/ndbapi/Makefile.am: Remove NdbResultSet ndb/src/ndbapi/NdbConnection.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbIndexOperation.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbScanOperation.cpp: Remove NdbResultSet ndb/test/include/HugoOperations.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanFunctions.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanInterpretTest.hpp: Remove NdbResultSet ndb/test/ndbapi/bank/Bank.cpp: Remove NdbResultSet ndb/test/ndbapi/bank/BankLoad.cpp: Remove NdbResultSet ndb/test/ndbapi/slow_select.cpp: Remove NdbResultSet ndb/test/ndbapi/testBlobs.cpp: Remove NdbResultSet ndb/test/ndbapi/testDataBuffers.cpp: Remove NdbResultSet ndb/test/ndbapi/testDeadlock.cpp: Remove NdbResultSet ndb/test/ndbapi/testIndex.cpp: Remove NdbResultSet ndb/test/ndbapi/testOIBasic.cpp: Remove NdbResultSet ndb/test/ndbapi/testReadPerf.cpp: Remove NdbResultSet ndb/test/ndbapi/testScan.cpp: Remove NdbResultSet ndb/test/ndbapi/testScanPerf.cpp: Remove NdbResultSet ndb/test/src/HugoOperations.cpp: Remove NdbResultSet ndb/test/src/HugoTransactions.cpp: Remove NdbResultSet ndb/test/src/UtilTransactions.cpp: Remove NdbResultSet ndb/tools/delete_all.cpp: Remove NdbResultSet ndb/tools/select_all.cpp: Remove NdbResultSet ndb/tools/select_count.cpp: Remove NdbResultSet sql/ha_ndbcluster.cc: 1) Fix a = 3 -> a= 3 2) Impl. last part of wl2126 ordered "multi ordered scan"
2004-12-07 15:15:49 +01:00
while((check = pOp->nextResult(true)) == 0){
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
do {
wl2126 - ndb - fix last unhandled part of read_multi_range reading sorted multi_range with several range-scans BitKeeper/deleted/.del-NdbResultSet.hpp~e0042f4c18088ff6: Delete: ndb/include/ndbapi/NdbResultSet.hpp BitKeeper/deleted/.del-NdbResultSet.cpp~84d192cf3f42600d: Delete: ndb/src/ndbapi/NdbResultSet.cpp ndb/include/ndbapi/NdbApi.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbIndexScanOperation.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbScanOperation.hpp: Remove NdbResultSet ndb/src/ndbapi/Makefile.am: Remove NdbResultSet ndb/src/ndbapi/NdbConnection.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbIndexOperation.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbScanOperation.cpp: Remove NdbResultSet ndb/test/include/HugoOperations.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanFunctions.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanInterpretTest.hpp: Remove NdbResultSet ndb/test/ndbapi/bank/Bank.cpp: Remove NdbResultSet ndb/test/ndbapi/bank/BankLoad.cpp: Remove NdbResultSet ndb/test/ndbapi/slow_select.cpp: Remove NdbResultSet ndb/test/ndbapi/testBlobs.cpp: Remove NdbResultSet ndb/test/ndbapi/testDataBuffers.cpp: Remove NdbResultSet ndb/test/ndbapi/testDeadlock.cpp: Remove NdbResultSet ndb/test/ndbapi/testIndex.cpp: Remove NdbResultSet ndb/test/ndbapi/testOIBasic.cpp: Remove NdbResultSet ndb/test/ndbapi/testReadPerf.cpp: Remove NdbResultSet ndb/test/ndbapi/testScan.cpp: Remove NdbResultSet ndb/test/ndbapi/testScanPerf.cpp: Remove NdbResultSet ndb/test/src/HugoOperations.cpp: Remove NdbResultSet ndb/test/src/HugoTransactions.cpp: Remove NdbResultSet ndb/test/src/UtilTransactions.cpp: Remove NdbResultSet ndb/tools/delete_all.cpp: Remove NdbResultSet ndb/tools/select_all.cpp: Remove NdbResultSet ndb/tools/select_count.cpp: Remove NdbResultSet sql/ha_ndbcluster.cc: 1) Fix a = 3 -> a= 3 2) Impl. last part of wl2126 ordered "multi ordered scan"
2004-12-07 15:15:49 +01:00
if (pOp->deleteCurrentTuple() != 0){
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
goto failed;
}
deletedRows++;
wl2126 - ndb - fix last unhandled part of read_multi_range reading sorted multi_range with several range-scans BitKeeper/deleted/.del-NdbResultSet.hpp~e0042f4c18088ff6: Delete: ndb/include/ndbapi/NdbResultSet.hpp BitKeeper/deleted/.del-NdbResultSet.cpp~84d192cf3f42600d: Delete: ndb/src/ndbapi/NdbResultSet.cpp ndb/include/ndbapi/NdbApi.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbIndexScanOperation.hpp: Remove NdbResultSet ndb/include/ndbapi/NdbScanOperation.hpp: Remove NdbResultSet ndb/src/ndbapi/Makefile.am: Remove NdbResultSet ndb/src/ndbapi/NdbConnection.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbIndexOperation.cpp: Remove NdbResultSet ndb/src/ndbapi/NdbScanOperation.cpp: Remove NdbResultSet ndb/test/include/HugoOperations.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanFunctions.hpp: Remove NdbResultSet ndb/test/ndbapi/ScanInterpretTest.hpp: Remove NdbResultSet ndb/test/ndbapi/bank/Bank.cpp: Remove NdbResultSet ndb/test/ndbapi/bank/BankLoad.cpp: Remove NdbResultSet ndb/test/ndbapi/slow_select.cpp: Remove NdbResultSet ndb/test/ndbapi/testBlobs.cpp: Remove NdbResultSet ndb/test/ndbapi/testDataBuffers.cpp: Remove NdbResultSet ndb/test/ndbapi/testDeadlock.cpp: Remove NdbResultSet ndb/test/ndbapi/testIndex.cpp: Remove NdbResultSet ndb/test/ndbapi/testOIBasic.cpp: Remove NdbResultSet ndb/test/ndbapi/testReadPerf.cpp: Remove NdbResultSet ndb/test/ndbapi/testScan.cpp: Remove NdbResultSet ndb/test/ndbapi/testScanPerf.cpp: Remove NdbResultSet ndb/test/src/HugoOperations.cpp: Remove NdbResultSet ndb/test/src/HugoTransactions.cpp: Remove NdbResultSet ndb/test/src/UtilTransactions.cpp: Remove NdbResultSet ndb/tools/delete_all.cpp: Remove NdbResultSet ndb/tools/select_all.cpp: Remove NdbResultSet ndb/tools/select_count.cpp: Remove NdbResultSet sql/ha_ndbcluster.cc: 1) Fix a = 3 -> a= 3 2) Impl. last part of wl2126 ordered "multi ordered scan"
2004-12-07 15:15:49 +01:00
} while((check = pOp->nextResult(false)) == 0);
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
if(check != -1){
check = pTrans->execute(Commit);
pTrans->restart();
ndb make updates ndb/src/common/portlib/NdbCondition.c: Rename: ndb/src/common/portlib/unix/NdbCondition.c -> ndb/src/common/portlib/NdbCondition.c ndb/src/common/portlib/NdbDaemon.c: Rename: ndb/src/common/portlib/unix/NdbDaemon.c -> ndb/src/common/portlib/NdbDaemon.c ndb/src/common/portlib/NdbEnv.c: Rename: ndb/src/common/portlib/unix/NdbEnv.c -> ndb/src/common/portlib/NdbEnv.c ndb/src/common/portlib/NdbHost.c: Rename: ndb/src/common/portlib/unix/NdbHost.c -> ndb/src/common/portlib/NdbHost.c ndb/src/common/portlib/NdbMem.c: Rename: ndb/src/common/portlib/unix/NdbMem.c -> ndb/src/common/portlib/NdbMem.c ndb/src/common/portlib/NdbMutex.c: Rename: ndb/src/common/portlib/unix/NdbMutex.c -> ndb/src/common/portlib/NdbMutex.c ndb/src/common/portlib/NdbSleep.c: Rename: ndb/src/common/portlib/unix/NdbSleep.c -> ndb/src/common/portlib/NdbSleep.c ndb/src/common/portlib/NdbTCP.c: Rename: ndb/src/common/portlib/unix/NdbTCP.c -> ndb/src/common/portlib/NdbTCP.c ndb/src/common/portlib/NdbThread.c: Rename: ndb/src/common/portlib/unix/NdbThread.c -> ndb/src/common/portlib/NdbThread.c ndb/src/common/portlib/NdbTick.c: Rename: ndb/src/common/portlib/unix/NdbTick.c -> ndb/src/common/portlib/NdbTick.c BitKeeper/deleted/.del-Makefile.am~4d9c81a4353f3ee8: Delete: ndb/src/common/portlib/unix/Makefile.am ndb/src/common/portlib/old_dirs/unix/Makefile_old: mvdir ndb/src/common/portlib/old_dirs/win32/Makefile: mvdir ndb/src/common/portlib/old_dirs/win32/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbDaemon.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/win32/NdbTick.c: mvdir ndb/src/common/portlib/old_dirs/ose/Makefile: mvdir ndb/src/common/portlib/old_dirs/ose/NdbCondition.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbConditionOSE.h: mvdir ndb/src/common/portlib/old_dirs/ose/NdbEnv.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbHost.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMem_SoftOse.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbMutex.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbOut.cpp: mvdir ndb/src/common/portlib/old_dirs/ose/NdbSleep.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTCP.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbThread.c: mvdir ndb/src/common/portlib/old_dirs/ose/NdbTick.c: mvdir ndb/src/common/portlib/memtest.c: Rename: ndb/src/common/portlib/memtest/memtest.c -> ndb/src/common/portlib/memtest.c ndb/src/common/portlib/munmaptest.cpp: Rename: ndb/src/common/portlib/memtest/munmaptest/munmaptest.cpp -> ndb/src/common/portlib/munmaptest.cpp ndb/src/common/portlib/mmslist.cpp: Rename: ndb/src/common/portlib/mmstest/mmslist.cpp -> ndb/src/common/portlib/mmslist.cpp ndb/src/common/portlib/mmstest.cpp: Rename: ndb/src/common/portlib/mmstest/mmstest.cpp -> ndb/src/common/portlib/mmstest.cpp ndb/src/common/portlib/old_dirs/memtest/Makefile: mvdir ndb/src/common/portlib/old_dirs/memtest/munmaptest/Makefile: mvdir ndb/src/common/portlib/NdbPortLibTest.cpp: Rename: ndb/src/common/portlib/test/NdbPortLibTest.cpp -> ndb/src/common/portlib/NdbPortLibTest.cpp ndb/src/common/portlib/old_dirs/test/Makefile: mvdir
2004-06-03 20:25:46 +02:00
}
err = pTrans->getNdbError();
if(check == -1){
if(err.status == NdbError::TemporaryError){
ERR(err);
pNdb->closeTransaction(pTrans);
NdbSleep_MilliSleep(50);
par = 1;
goto restart;
}
goto failed;
}
}
if(check == -1){
err = pTrans->getNdbError();
if(err.status == NdbError::TemporaryError){
ERR(err);
pNdb->closeTransaction(pTrans);
NdbSleep_MilliSleep(50);
par = 1;
goto restart;
}
goto failed;
}
pNdb->closeTransaction(pTrans);
return NDBT_OK;
}
return NDBT_FAILED;
failed:
if(pTrans != 0) pNdb->closeTransaction(pTrans);
ERR(err);
return (err.code != 0 ? err.code : NDBT_FAILED);
}