We are moving to Git Issues for bug tracking in future releases. During transition, content will be in both tools. If you'd like to file a new bug, please create an issue.

Bug 3793 - Can't update section info with 2.2.2 and Postgres
Can't update section info with 2.2.2 and Postgres
Status: RESOLVED DUPLICATE of bug 3790
Product: OJS
Classification: Unclassified
Component: Journal Management
PC Linux
: P1 normal
Assigned To: PKP Support
Depends on:
  Show dependency treegraph
Reported: 2008-09-28 19:40 PDT by David Kaloper
Modified: 2008-09-28 19:43 PDT (History)
0 users

See Also:
Version Reported In:
Also Affects:

a caveman's fix (2.64 KB, patch)
2008-09-28 19:42 PDT, David Kaloper
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Kaloper 2008-09-28 19:40:10 PDT
After updating from 2.1 to 2.2.2, any attempt to edit sections returns:

DB Error: ERROR: invalid input syntax for integer: ""

Turns out, our sections.review_form_id are all NULL and Postgres just won't have any of that do-magick-with-nulls MySQL promotes.

The problem lies with the query in classes/journal/SectionDAO.inc.php:updateSection where $section->getReviewFormId is UPDATEd back to database and becomes an empty string if null.

PostgreSQL 8.1.9, Apache 2.2.6, PHP 5.2.5, Linux

Attaching an extremely crude patch for the benefit of anyone having this problem and needing a quick fix before Alec does it for real.
Comment 1 David Kaloper 2008-09-28 19:42:15 PDT
Created attachment 992 [details]
a caveman's fix
Comment 2 Alec Smecher 2008-09-28 19:43:25 PDT

*** This bug has been marked as a duplicate of bug 3790 ***