/[projects]/dao/FuldDaekningWorker/src/dk/daoas/fulddaekning/Database.java
ViewVC logotype

Diff of /dao/FuldDaekningWorker/src/dk/daoas/fulddaekning/Database.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2328 by torben, Thu Feb 19 13:39:33 2015 UTC revision 2331 by torben, Fri Feb 20 08:58:19 2015 UTC
# Line 172  public class Database { Line 172  public class Database {
172                    
173                          // Forward only + concur_read_only + fetchsize tvinger driver til at hente en række af gangen (bedre performance ved store result sets)                          // Forward only + concur_read_only + fetchsize tvinger driver til at hente en række af gangen (bedre performance ved store result sets)
174                          // Se http://dev.mysql.com/doc/connector-j/en/connector-j-reference-implementation-notes.html                          // Se http://dev.mysql.com/doc/connector-j/en/connector-j-reference-implementation-notes.html
                         //PreparedStatement stmt = conn.prepareStatement(sql);  
175                          PreparedStatement stmt = conn.prepareStatement(sql, java.sql.ResultSet.TYPE_FORWARD_ONLY, java.sql.ResultSet.CONCUR_READ_ONLY);                          PreparedStatement stmt = conn.prepareStatement(sql, java.sql.ResultSet.TYPE_FORWARD_ONLY, java.sql.ResultSet.CONCUR_READ_ONLY);
176                          stmt.setFetchSize(Integer.MIN_VALUE);                          stmt.setFetchSize(Integer.MIN_VALUE);
177                    
# Line 305  public class Database { Line 304  public class Database {
304    
305                    
306          // //////////////////////////////////////////////////////////////////          // //////////////////////////////////////////////////////////////////
307                    /*
308          @Deprecated          @Deprecated
309          private BoundingBox getBoundingboxFromDb_old(String postnr) throws SQLException {          private BoundingBox getBoundingboxFromDb_old(String postnr) throws SQLException {
310                  String minPostnr = postnr.replace('x', '0');                  String minPostnr = postnr.replace('x', '0');
# Line 401  public class Database { Line 400  public class Database {
400                                           "AND rute is null " + // Træk kun liste på postnumre hvor der er ikke-dækkede adresser                                           "AND rute is null " + // Træk kun liste på postnumre hvor der er ikke-dækkede adresser
401                                           "GROUP BY postnr " +                                           "GROUP BY postnr " +
402                                           "ORDER by postnr";                                           "ORDER by postnr";
403                  */                  * /
404                                    
405                                    
406                  String sql = "SELECT rpad(left(postnr,?),'4', 'x') as postnr2 " +                  String sql = "SELECT rpad(left(postnr,?),'4', 'x') as postnr2 " +
# Line 433  public class Database { Line 432  public class Database {
432                  //list.add(8700);                  //list.add(8700);
433    
434                  return list;                  return list;
435          }          }*/
436    
437                    
438  }  }

Legend:
Removed from v.2328  
changed lines
  Added in v.2331

  ViewVC Help
Powered by ViewVC 1.1.20