Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0033219
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorhave not tried2016-06-10 18:012016-06-20 13:11
ReportershuehnerView Statuspublic 
Assigned Toshuehner 
PrioritynormalResolutionfixedFixed in Version3.0PR16Q3
StatusclosedFix in branchFixed in SCM revision7b9f6cdbce15
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toalostale
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0033219: Avoid unnecessary cast from String to String in SqlC generated code

DescriptionWhen SqlC generates code to run callable statements it produces some extra casts which are not needed.

Example:
org.openbravo.erpCommon.ad_forms.AccountData
method: GetValidAccountCombination

      Vector<String> vecTotal = new Vector<String>();
      try {
        vecTotal = RDBMSIndependent.getCallableResult(conn, connectionProvider, strSql, parametersData, parametersTypes, 1);
      objectRespuestaCS.CValidCombinationId = (String) vecTotal.elementAt(0);

as vecTotal is a Vector of String that cast to String is not needed.

Searching all SqlC.java file for 'vecTotal' shows the definition to be always like that so the extra cast can be safely removed.
Steps To ReproduceI.e. enable optional eclipse warnings 'unnecessary casts'.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0087180)
hgbot (developer)
2016-06-10 19:03

Repository: erp/devel/pi
Changeset: 7b9f6cdbce15830656b9e94636afd31a3dd9222a
Author: Stefan Hühner <stefan.huehner <at> openbravo.com>
Date: Fri Jun 10 19:02:58 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/7b9f6cdbce15830656b9e94636afd31a3dd9222a [^]

Fixed 33219. Avoid unnecessary cast in SqlC generated code.

---
M src-core/src/org/openbravo/data/Sqlc.java
---
(0087671)
alostale (manager)
2016-06-20 13:11

code reviewed: the only modifications in generated sqlc code is the removal of these unnecessary castings.

- Issue History
Date Modified Username Field Change
2016-06-10 18:01 shuehner New Issue
2016-06-10 18:01 shuehner Assigned To => shuehner
2016-06-10 18:01 shuehner Modules => Core
2016-06-10 18:01 shuehner Triggers an Emergency Pack => No
2016-06-10 19:03 hgbot Checkin
2016-06-10 19:03 hgbot Note Added: 0087180
2016-06-10 19:03 hgbot Status new => resolved
2016-06-10 19:03 hgbot Resolution open => fixed
2016-06-10 19:03 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/7b9f6cdbce15830656b9e94636afd31a3dd9222a [^]
2016-06-10 19:04 shuehner Review Assigned To => alostale
2016-06-20 13:11 alostale Note Added: 0087671
2016-06-20 13:11 alostale Status resolved => closed
2016-06-20 13:11 alostale Fixed in Version => 3.0PR16Q3


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker