Koha-clms/misc/migration_tools
Magnus Enger 1e65ab6f7f
Bug 12488: Make bulkmarcimport.pl -d use DELETE instead of TRUNCATE
On MySQL >= 5.5 bulkmarcimport.pl with the -d (delete) switch gives
an error like "Cannot truncate a table referenced in a foreign
key constraint". This patch proposes to replace the offending
TRUNCATE with DELETE. Auto incerement counters are reset to 1 to
preserve the functionality from TRUNCATE.

To test:
- Make sure you havae a test database with some records and items
- Run bulkmarcimport.pl with the -d switch
- Observe the error described above
- Apply this patch
- Run bulkmarcimport.pl with the -d switch again
- Observe the lack of an error
- Verify that the newly imported records and items have biblionumber
  and itemnumbers starting with 1

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
(cherry picked from commit b7b4694666)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
2019-02-25 13:29:39 +00:00
..
22_to_30 Bug 19040: Update 2 occurrences of GetMarcBiblio in 22_to_30 2017-08-25 10:51:24 -03:00
buildCOUNTRY.pl
…
buildEDITORS.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00
buildLANG.pl
…
build_oai_sets.pl Bug 14385: Squash of a lot of patches rebased 2018-11-02 10:33:12 +00:00
bulkmarcimport.pl Bug 12488: Make bulkmarcimport.pl -d use DELETE instead of TRUNCATE 2019-02-25 13:29:39 +00:00
checkNonIndexedBiblios.pl Bug 12478: make things using SimpleSearch use the new version 2016-04-26 20:20:07 +00:00
create_analytical_rel.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00
fix_onloan.pl
…
import_lexile.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00
koha-svc.pl
…
rebuild_zebra.pl Bug 21908: (QA follow-up) Remove useless parentheses in query 2018-12-12 10:56:13 +00:00
rebuild_zebra_sliced.sh Bug 13660: Exclude export phase and use existing exported MARCXML - rebuild_zebra_sliced.sh 2018-01-09 17:23:50 -03:00
remove_unused_authorities.pl Bug 9988: Merge should have a parameter hash 2017-04-13 08:53:46 -04:00
switch_marc21_series_info.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00
upgradeitems.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00