The SetImportBatchNoMatchAction options are hard coded in this script, they should be operators.
Created attachment 28330 [details] [review] Bug 12289: Add nomatch options to stage_file.pl This patch adds the nomatch options to the command line interface for bulk loading of records.
This patch adds a control operator to allow for the setting of 'ignore' in SetImportBatchNoMatchAction. To test, call the script with --no-create and your will find that new records are not created when no match is found. The default, of create_new remains the same as before.
I get this error when running the script after the patch: Global symbol "$no_create" requires explicit package name at ./misc/stage_file.pl line 57. Global symbol "$no_create" requires explicit package name at ./misc/stage_file.pl line 123. Execution of ./misc/stage_file.pl aborted due to compilation errors.
Created attachment 42134 [details] [review] Bug 12289: (follow-up) fix the compilation error
Now it looks to me that this is working as it should. Someone, sign-off this please! :)
Created attachment 45964 [details] [review] Bug 12289: Add --no-create options to stage_file.pl This patch adds the no-create options to the command line interface for bulk loading of records. To test 1/ Apply both patches 2/ Call the script with --no-create and your will find that new records are not created when no match is found. The default, of create_new remains the same as before. Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Created attachment 45965 [details] [review] Bug 12289: (follow-up) fix the compilation error Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Created attachment 45985 [details] [review] Bug 12289: Add --no-create options to stage_file.pl This patch adds the no-create options to the command line interface for bulk loading of records. To test 1/ Apply both patches 2/ Call the script with --no-create and your will find that new records are not created when no match is found. The default, of create_new remains the same as before. Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 45986 [details] [review] Bug 12289: (follow-up) fix the compilation error Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
pushed to master - thanks