Bug 11010 - Useless column purchaseordernumber in aqorders table
Summary: Useless column purchaseordernumber in aqorders table
Status: CLOSED INVALID
Alias: None
Product: Koha
Classification: Unclassified
Component: Database (show other bugs)
Version: master
Hardware: All All
: P5 - low minor (vote)
Target Milestone: ---
Assignee: Galen Charlton
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-10-07 15:43 UTC by mathieu saby
Modified: 2015-06-04 23:24 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mathieu saby 2013-10-07 15:43:08 UTC
In Schemaspy, column purchaseordernumber is reported as "not used? always NULL".
"grep -r cancelledby *" give this result : 

C4/Acquisition.pm:The following keys are used: "biblionumber", "title", "basketno", "quantity", "notes", "rrp", "ecost", "gstrate", "unitprice", "subscription", "sort1", "sort2", "booksellerinvoicenumber", "listprice", "budgetdate", "purchaseordernumber", "branchcode", "booksellerinvoicenumber", "budget_id".
C4/Acquisition.pm:                datereceived,purchaseordernumber,
installer/data/mysql/update22to30.pl:                field   => 'purchaseordernumber',
installer/data/mysql/kohastructure.sql:  `purchaseordernumber` mediumtext, -- not used? always NULL
installer/data/Pg/kohastructure.sql:purchaseordernumber text,
t/db_dependent/Acquisition.t:                         purchaseordernumber


In C4::Acquisition.pm::GetParcels, the SELECT statement retreives purchaseordernumber, but no value is pushed to that column in any part of Koha's code. So I think it is useless.

I propose the deletion of this column.

M. Saby
Comment 1 Colin Campbell 2013-10-07 16:26:16 UTC
There is a patch on bug 4456 to utilize this field. see also bug 4960
Comment 2 mathieu saby 2013-10-07 17:20:59 UTC
Thank you.
4456 is very old, and there is nothing attached to 4456.
Do you think these enh could be "revived" ?
What's the difference between the ordernumber and the purchaseordernumber?

M. Saby
Comment 3 mathieu saby 2013-10-07 17:21:43 UTC
oups, the patch attached to 4456 is not very old, sorry for that.

M. Saby
Comment 4 Jonathan Druart 2014-07-18 10:32:12 UTC
Since bug 4456 will use this field, this bug report is invalid.