Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0007411Openbravo ERPZ. Otherspublic2009-02-02 14:272009-03-04 16:38
shuehner 
dalsasua 
normalmajorhave not tried
closedfixed 
5
2.40MP1 
2.40MP3 
Core
No
0007411: Invalid substr index (=0) in SQL query.
We have several occurences of substr(<some string>,0,<length>) in the codebase. The first parameter is 1-based per SQL spec and a value of 0 does not work as expected on postgres.

List of affected files on both 2.40 and trunk:

- src-db/database/model/functions/C_COMMISSION_PROCESS.xml (2 times)
- src/org/openbravo/erpCommon/ad_actionButton/CreateFile_data.xsql
- src/org/openbravo/erpCommon/ad_forms/InitialOrgSetup_data.xsql (trunk only)

More Files covered by different issues:

- src/org/openbravo/erpCommon/ad_forms/FileImport_data.xsql (7130, function is unused)
- src/org/openbravo/erpCommon/ad_forms/InitialClientSetup_data.xsql (7129, already resolved)
No tags attached.
blocks defect 0007315 closed dalsasua Invalid substr index (=0) in SQL query. 
Issue History
2009-02-06 11:36dalsasuaTypedefect => backport
2009-02-06 11:36dalsasuafix_in_branch => 2.40
2009-02-06 11:41svnbotCheckin
2009-02-06 11:41svnbotNote Added: 0013213
2009-02-06 11:41svnbotStatusscheduled => resolved
2009-02-06 11:41svnbotResolutionopen => fixed
2009-02-06 11:41svnbotsvn_revision12880 => 12881
2009-03-03 17:32psarobeFixed in Version => 2.40MP3
2009-03-04 16:38psarobeStatusresolved => closed

Notes
(0013213)
svnbot   
2009-02-06 11:41   
Repository: openbravo
Revision: 12881
Author: davidalsasua
Date: 2009-02-06 11:41:12 +0100 (Fri, 06 Feb 2009)

Fixes Bug 0007411: Invalid substr index (=0) in SQL query.

---
U branches/r2.40/src/org/openbravo/erpCommon/ad_actionButton/CreateFile_data.xsql
U branches/r2.40/src-db/database/model/functions/C_COMMISSION_PROCESS.xml
---

https://dev.openbravo.com/websvn/openbravo/?rev=12881&sc=1 [^]