Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0030529Openbravo ERP04. Warehouse managementpublic2015-08-07 12:102015-08-10 09:12
alostale 
AtulOpenbravo 
immediatemajorhave not tried
closedfixed 
5
 
3.0PR15Q2.4 
vmromanos
Core
Production - Confirmed Stable
2015-02-15
3.0PR15Q2
https://code.openbravo.com/erp/devel/pi/rev/b4be2e4511445d578fc7f8a2175c3a6114e52583 [^]
No
0030529: Potential full c_orderline scan in M_Reservation_trg
Trigger on M_Reservation table does a count on all order lines without any filtering.

If this code is executed in an environment with a decent amount of orders, it can take ages to complete.





I have not reproduced it, but just read the code in M_RESERVATION_TRG.xml :

https://code.openbravo.com/erp/devel/pi/rev/b4be2e4511445d578fc7f8a2175c3a6114e52583#l1.28 [^]

select count (*) into v_count from c_orderline;

it looks like some missing debug code forgotten to remove as it is never used
Approved
blocks defect 0030516 closed AtulOpenbravo Potential full c_orderline scan in M_Reservation_trg 
Issue History
2015-08-10 06:51AtulOpenbravoTypedefect => backport
2015-08-10 06:51AtulOpenbravoTarget Version => 3.0PR15Q2.4
2015-08-10 09:11vmromanosTag Attached: Approved
2015-08-10 09:12hgbotCheckin
2015-08-10 09:12hgbotNote Added: 0079270
2015-08-10 09:12hgbotStatusscheduled => resolved
2015-08-10 09:12hgbotResolutionopen => fixed
2015-08-10 09:12hgbotFixed in SCM revision => http://code.openbravo.com/erp/backports/3.0PR15Q2.4/rev/14a82c0a34bd2974fe1836847ea6ec5fd2fd3a0f [^]
2015-08-10 09:12vmromanosReview Assigned To => vmromanos
2015-08-10 09:12vmromanosStatusresolved => closed

Notes
(0079270)
hgbot   
2015-08-10 09:12   
Repository: erp/backports/3.0PR15Q2.4
Changeset: 14a82c0a34bd2974fe1836847ea6ec5fd2fd3a0f
Author: Atul Gaware <atul.gaware <at> openbravo.com>
Date: Mon Aug 10 10:22:48 2015 +0530
URL: http://code.openbravo.com/erp/backports/3.0PR15Q2.4/rev/14a82c0a34bd2974fe1836847ea6ec5fd2fd3a0f [^]

Fixes Issue 30529:Potential full c_orderline scan in M_Reservation_trg

Removed unwanted line in code which fully scans c_orderline.

---
M src-db/database/model/triggers/M_RESERVATION_TRG.xml
---