Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0025683 | Openbravo ERP | I. Performance | public | 2014-02-07 07:49 | 2014-02-19 11:59 |
|
Reporter | shuehner | |
Assigned To | dmiguelez | |
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | 3.0MP22.2 | |
Target Version | | Fixed in Version | 3.0PR14Q2 | |
Merge Request Status | |
Review Assigned To | shuehner |
OBNetwork customer | OBPS |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0025683: c_order_trg is doing updates to c_invoice when not needed |
Description | The logic in c_order_trg is executing the updates to the c_invoice table when it is not needed.
The trigger has some code for checking that some fields changed, but they seem to be too wide.
Example, not processed order, if c_bpartner_id (only this) changes we do update c_invoice even if that update does not use that columns. |
Steps To Reproduce | Read trigger code |
Proposed Solution | Change logic in trigger:
Put the if.processed='Y' first as top level if
Then put 2nd top-level if with just checking if description or poreference change as check if to update c_invoice or not.
NOTE: this assume that we only want to update the c_invoice if one of the fields mentioned in the update statement are changed.
|
Additional Information | |
Tags | Performance |
Relationships | related to | defect | 0025682 | | closed | shuehner | Missing index for c_invoice table c_order_id column makes at least c_order_trg + c_order_trg2 slow |
|
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2014-02-07 07:49 | shuehner | New Issue | |
2014-02-07 07:49 | shuehner | Assigned To | => AugustoMauch |
2014-02-07 07:49 | shuehner | Modules | => Core |
2014-02-07 07:49 | shuehner | OBNetwork customer | => No |
2014-02-07 07:49 | shuehner | Triggers an Emergency Pack | => No |
2014-02-07 07:49 | shuehner | Relationship added | related to 0025682 |
2014-02-07 07:57 | shuehner | OBNetwork customer | No => Yes |
2014-02-07 08:02 | alostale | Tag Attached: Performance | |
2014-02-07 08:03 | alostale | Assigned To | AugustoMauch => dmiguelez |
2014-02-07 12:31 | eduardo_Argal | Status | new => scheduled |
2014-02-07 12:31 | eduardo_Argal | fix_in_branch | => pi |
2014-02-07 12:32 | hgbot | Checkin | |
2014-02-07 12:32 | hgbot | Note Added: 0064014 | |
2014-02-07 12:32 | hgbot | Status | scheduled => resolved |
2014-02-07 12:32 | hgbot | Resolution | open => fixed |
2014-02-07 12:32 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/b4367a3c856cf6ae8d2c7f2d4c58ce2cd0ecdef6 [^] |
2014-02-07 12:54 | hgbot | Checkin | |
2014-02-07 12:54 | hgbot | Note Added: 0064015 | |
2014-02-07 12:54 | hgbot | Fixed in SCM revision | http://code.openbravo.com/erp/devel/pi/rev/b4367a3c856cf6ae8d2c7f2d4c58ce2cd0ecdef6 [^] => http://code.openbravo.com/erp/devel/pi/rev/4ddcfa6e2e4c33124ef23c3b47c22eddf592bdf9 [^] |
2014-02-12 18:30 | hudsonbot | Checkin | |
2014-02-12 18:30 | hudsonbot | Note Added: 0064172 | |
2014-02-12 18:30 | hudsonbot | Checkin | |
2014-02-12 18:30 | hudsonbot | Note Added: 0064173 | |
2014-02-19 11:59 | shuehner | Review Assigned To | => shuehner |
2014-02-19 11:59 | shuehner | Note Added: 0064349 | |
2014-02-19 11:59 | shuehner | Status | resolved => closed |
2014-02-19 11:59 | shuehner | Fixed in Version | => 3.0MP32 |
Notes |
|
(0064014)
|
hgbot
|
2014-02-07 12:32
|
|
Repository: erp/devel/pi
Changeset: b4367a3c856cf6ae8d2c7f2d4c58ce2cd0ecdef6
Author: Eduardo Argal Guibert <eduardo.argal <at> openbravo.com>
Date: Fri Feb 07 12:31:59 2014 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/b4367a3c856cf6ae8d2c7f2d4c58ce2cd0ecdef6 [^]
Fixes bug 25683: trigger performance improvement
---
M modules/org.openbravo.advpaymentmngt/src-db/database/model/modifiedTables/FIN_BANKSTATEMENT.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/model/modifiedTables/FIN_FINANCIAL_ACCOUNT.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/model/triggers/APRM_FIN_BNKSTM_LINE_CHECK_TRG.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/model/triggers/APRM_FIN_RECON_CHECK_TRG.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_AUXILIARINPUT.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_COLUMN.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_ELEMENT.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_FIELD.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MENU.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MESSAGE.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODEL_OBJECT.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODEL_OBJECT_MAPPING.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_PROCESS.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_PROCESS_PARA.xml
M modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_TREENODE.xml
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransaction.java
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/dao/MatchTransactionDao.java
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_BankStatementProcess.java
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_ReconciliationProcess.java
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/utility/FIN_BankStatementImport.java
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-action-button.js
M src-db/database/model/tables/FACT_ACCT.xml
M src-db/database/model/triggers/C_ORDER_TRG.xml
M src-db/database/sourcedata/AD_AUXILIARINPUT.xml
M src-db/database/sourcedata/AD_COLUMN.xml
M src-db/database/sourcedata/AD_ELEMENT.xml
---
|
|
|
(0064015)
|
hgbot
|
2014-02-07 12:54
|
|
|
|
|
|
|
|
|
|
|
Reviewed and test on oracle/pgsql.
If changing either poreference or description columns of an c_order the attached c_invoice (if there is one) will get those two fields updates.
However small behavior change:
Before those columns were updated in invoice on any change to attached order.
Now they will only be updated if they have been modified.
So in following case behavior is different
- Have c_order with attached c_invoice
- edit order description, it will get sync to invoice.
- edit invoice description to be different
- edit order payment term -> now description in invoice will not be reverted back to be order description.
After discussing change with EAR deemed reasonable. |
|