Bug 4494 - Creating a new registration type results in error
Creating a new registration type results in error
Status: RESOLVED FIXED
Product: OCS
Classification: Unclassified
Component: General
2.1.2
PC Mac OS X 10.3
: P5 major
Assigned To: Alec Smecher
: 4762 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-06-29 11:47 PDT by James MacGregor
Modified: 2009-11-18 06:49 PST (History)
5 users (show)

See Also:
Version Reported In:
Also Affects:


Attachments
Patch against OCS 2.1.2-0 (374 bytes, patch)
2009-06-29 16:59 PDT, Alec Smecher
Details | Diff
Patch against OCS 2.1.2 (436 bytes, patch)
2009-11-18 06:49 PST, Alec Smecher
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description James MacGregor 2009-06-29 11:47:41 PDT
If I try to create a new registration type, I get the following error and the registration type isn't created: 

DB Error: Unknown column 'cost' in 'field list'

Courtesy of http://pkp.sfu.ca/support/forum/viewtopic.php?f=3&t=4665&p=18153#p18153. I tried this on a fresh install of 2.1.2. Tried changing the registration options in Website Management 2.5, but that didn't have an effect.
Comment 1 Michael Felczak 2009-06-29 12:40:03 PDT
I started to take a look at this and noticed that there were some major and minor updates to the registration code for 2.1.2 -- Juan or Matt since these enhancements/bug fixes were mainly yours would you mind taking a look at this? (will be faster than me trying to track this down).
Comment 2 Matthew Crider 2009-06-29 13:13:19 PDT
It looks like this is related to bug 4416 -- Should that column ever have been taken out of the schema?  I don't think I ever worked with this code (at least not in the stable branch), so I'm not sure what exactly is going on.
Comment 3 Alec Smecher 2009-06-29 16:59:39 PDT
Created attachment 2062 [details]
Patch against OCS 2.1.2-0
Comment 4 Alec Smecher 2009-06-29 17:01:39 PDT
This can also be corrected by executing the following in MySQL:

ALTER TABLE registration_types ADD COLUMN cost FLOAT;
Comment 5 Alec Smecher 2009-07-02 15:10:12 PDT
This was caused by the "cost" column being removed from registration_types instead of registration_options. It's been restored to registration_types and removed from registration_options as it should've been for bug #4416.
Comment 6 Alec Smecher 2009-09-21 16:23:17 PDT
*** Bug 4762 has been marked as a duplicate of this bug. ***
Comment 7 Alec Smecher 2009-11-18 06:49:57 PST
Created attachment 2603 [details]
Patch against OCS 2.1.2