svn commit: r593448 - in /ofbiz/trunk/specialpurpose/bi: entitydef/entitymodel.xml src/org/ofbiz/bi/util/DimensionServices.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r593448 - in /ofbiz/trunk/specialpurpose/bi: entitydef/entitymodel.xml src/org/ofbiz/bi/util/DimensionServices.java

jacopoc
Author: jacopoc
Date: Fri Nov  9 00:28:18 2007
New Revision: 593448

URL: http://svn.apache.org/viewvc?rev=593448&view=rev
Log:
Changed field name frrom DateDimension.yearMonth to DateDimension.yearAndMonth because YEAR_MONTH is a reserved word in some databases. Thanks to Chris Lombardi for the bug report and proposed solution: OFBIZ-1391

Modified:
    ofbiz/trunk/specialpurpose/bi/entitydef/entitymodel.xml
    ofbiz/trunk/specialpurpose/bi/src/org/ofbiz/bi/util/DimensionServices.java

Modified: ofbiz/trunk/specialpurpose/bi/entitydef/entitymodel.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/bi/entitydef/entitymodel.xml?rev=593448&r1=593447&r2=593448&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/bi/entitydef/entitymodel.xml (original)
+++ ofbiz/trunk/specialpurpose/bi/entitydef/entitymodel.xml Fri Nov  9 00:28:18 2007
@@ -69,7 +69,7 @@
         <field name="yearMonthDay" type="short-varchar">
             <description>YYYY-MM-DD</description>
         </field>
-        <field name="yearMonth" type="short-varchar">
+        <field name="yearAndMonth" type="short-varchar">
             <description>YYYY-MM</description>
         </field>
         <field name="weekdayType" type="short-varchar">

Modified: ofbiz/trunk/specialpurpose/bi/src/org/ofbiz/bi/util/DimensionServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/bi/src/org/ofbiz/bi/util/DimensionServices.java?rev=593448&r1=593447&r2=593448&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/bi/src/org/ofbiz/bi/util/DimensionServices.java (original)
+++ ofbiz/trunk/specialpurpose/bi/src/org/ofbiz/bi/util/DimensionServices.java Fri Nov  9 00:28:18 2007
@@ -171,7 +171,7 @@
             dateValue.set("weekOfYear", new Long(calendar.get(Calendar.WEEK_OF_YEAR)));
             dateValue.set("weekdayType", (dayOfWeek == 1 || dayOfWeek == 7? "Weekend": "Weekday"));
             dateValue.set("yearMonthDay", yearMonthDayFormat.format(currentDate));
-            dateValue.set("yearMonth", yearMonthFormat.format(currentDate));
+            dateValue.set("yearAndMonth", yearMonthFormat.format(currentDate));
             
             try {
                 if (newValue) {