Invalid input syntax for integer when using Articles and Issues XML Plugin

Hi,

When importing via the articles and issues XML plugin, I get the following error (from debug output):

(postgres7): INSERT INTO article_supplementary_files
            (remote_url, file_id, article_id, type, date_created, language, show_reviewers, date_submitted, seq)
            VALUES
(?, ?, ?, ?, '1990-01-01', ?, ?, '2016-03-23 12:13:47', ?)  

[ (0=>'') (1=>'22906') (2=>'8941') (3=>'') (4=>'en') (5=>'') (6=>'0')  ]
 
-1: ERROR:  invalid input syntax for integer: ""

It looks like the show_reviewers field is causing the error (5=>’’ should be an integer), but I can’t find this anywhere in the input XML file. Also, our sequences seem ok in the article_supplementary_files table:

 Column     |            Type             |                                   Modifiers                                   

----------------±----------------------------±------------------------------------------------------------------------------
supp_id | integer | not null default nextval(‘article_supplementary_files_supp_id_seq’::regclass)

Not sure where to go from here - any suggestions?

All supplemental_file nodes have a type attribute with value “other”.

The import file itself is 22MB(!), could this be the problem?

Thanks,
Gary

Hi @gizzard,

Try applying this patch:

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

What is the recommended way to apply these patches (and can I download the patch ready to go from github?)?

Thanks,
Gary

Hi @gizzard,

You can download a patch from github by adding .diff to the end of the URL – in this case:
https://github.com/pkp/ojs/commit/0fe21b38a2efed830be9ac92bf5aaff24157eaa3.diff

Save this somewhere, then use the patch tool on your server to apply it, e.g.:

patch -p1 --dry-run < /path/to/patch-file.diff

If that appears to work, remove the --dry-run option to actually make the change.

Regards,
Alec Smecher
Public Knowledge Project Team