fix for libreofffice5.1.x
authorChristian Schwarzinger <christian.schwarzinger@proclos.com>
Wed, 25 May 2016 10:32:32 +0200
changeset 4170925dbb524f
parent 40 96d9e73117d5
child 42 7d1ee1c2004c
fix for libreofffice5.1.x
dist/PalOOCa.jar
dist/PalOOCa.oxt
dist/PalOOCa_IDL_types.jar
dist/external_jars/jars.properties
src/org/palooca/DataValueHandler.java
src/org/palooca/PalOOCaView.java
src/org/palooca/h2/OlapAggregator.java
     1.1 Binary file dist/PalOOCa.jar has changed
     2.1 Binary file dist/PalOOCa.oxt has changed
     3.1 Binary file dist/PalOOCa_IDL_types.jar has changed
     4.1 --- a/dist/external_jars/jars.properties	Thu May 07 09:04:40 2015 +0200
     4.2 +++ b/dist/external_jars/jars.properties	Wed May 25 10:32:32 2016 +0200
     4.3 @@ -1,3 +1,3 @@
     4.4  #PackageActionDescription
     4.5 -#Thu May 07 09:00:47 CEST 2015
     4.6 +#Wed May 25 10:27:43 CEST 2016
     4.7  external.jars=external_jars/dom4j-1.6.1.jar external_jars/swing-layout-1.0.4.jar external_jars/appframework-1.0.3.jar external_jars/swing-worker-1.1.jar external_jars/AbsoluteLayout.jar external_jars/log4j-1.2.16.jar external_jars/xercesImpl.jar external_jars/h2-1.3.172.jar external_jars/olap4j-1.2.0-SNAPSHOT.jar external_jars/olap4j-xmla-1.2.0-SNAPSHOT.jar external_jars/palojlib-5.1.jar external_jars/jdom-2.0.5.jar
     5.1 --- a/src/org/palooca/DataValueHandler.java	Thu May 07 09:04:40 2015 +0200
     5.2 +++ b/src/org/palooca/DataValueHandler.java	Wed May 25 10:32:32 2016 +0200
     5.3 @@ -46,9 +46,11 @@
     5.4      // To disable batching, set this to true
     5.5      private static boolean disableBatchFetch = false;
     5.6      private static boolean fixMissingCells = false;
     5.7 +    private static boolean firstError = true;
     5.8  
     5.9      protected static void beginReadFromBatchResults(){
    5.10          readFromBatchResults = true;
    5.11 +        System.err.println("start batch");
    5.12      }
    5.13  
    5.14      protected static void endReadFromBatchResults(){
    5.15 @@ -79,6 +81,7 @@
    5.16      }
    5.17  
    5.18      public static void endBatchUpdate(XComponentContext context,String cubeName) {
    5.19 +         System.err.println("end batch.");
    5.20           DataValueHandler.endReadFromBatchResults();
    5.21           cellLookup.remove(cubeName);
    5.22      }
    5.23 @@ -95,9 +98,18 @@
    5.24              if (DataValueHandler.getReadFromBatchResults()){
    5.25                  Map<String,ICell> preCalcLookup = cellLookup.get(getServerCubeCombo(servdb,cubeName));
    5.26                  if (preCalcLookup != null) {
    5.27 -                    cell = preCalcLookup.get(PaloLibUtil.getPathString(coordinates));
    5.28 +                    cell = preCalcLookup.get(PaloLibUtil.getPathString(coordinates).toLowerCase());
    5.29                      if (cell == null && fixMissingCells) {
    5.30                          cell = new Cell(new int[]{},0,CellType.CELL_NUMERIC,new IDimension[]{},new String[]{});
    5.31 +                    } else if (cell==null) {
    5.32 +                        System.out.println("Error in cell:" +PaloLibUtil.getPathString(coordinates));
    5.33 +                        if (firstError) {
    5.34 +                            firstError = false;
    5.35 +                            for (String s : preCalcLookup.keySet()) {
    5.36 +                                ICell c = preCalcLookup.get(s);
    5.37 +                                System.err.println(s+":"+c.getValue());
    5.38 +                            }
    5.39 +                        }
    5.40                      }
    5.41                  }
    5.42              }
     6.1 --- a/src/org/palooca/PalOOCaView.java	Thu May 07 09:04:40 2015 +0200
     6.2 +++ b/src/org/palooca/PalOOCaView.java	Wed May 25 10:32:32 2016 +0200
     6.3 @@ -915,7 +915,7 @@
     6.4                          }
     6.5                      }
     6.6                  }
     6.7 -                cells.put(PaloLibUtil.getPathString(exCell.getPathNames()), exCell);
     6.8 +                cells.put(PaloLibUtil.getPathString(exCell.getPathNames()).toLowerCase(), exCell);
     6.9              }
    6.10          }
    6.11  
     7.1 --- a/src/org/palooca/h2/OlapAggregator.java	Thu May 07 09:04:40 2015 +0200
     7.2 +++ b/src/org/palooca/h2/OlapAggregator.java	Wed May 25 10:32:32 2016 +0200
     7.3 @@ -89,7 +89,7 @@
     7.4                  }
     7.5                  //fix for aggDim = LastDim
     7.6                  if (coords[dimensions.length-1] == null) coords[dimensions.length-1] = aggregateElementName;
     7.7 -                String key = PaloLibUtil.getPathString(coords);
     7.8 +                String key = PaloLibUtil.getPathString(coords).toLowerCase();
     7.9                  result.put(key, new Cell(new int[]{},value,CellType.CELL_NUMERIC,new IDimension[]{}, new String[]{}));
    7.10              }
    7.11           } catch (SQLException sqle) {