Parent Directory | Revision Log | Patch
revision 2156 by torben, Wed May 7 08:10:45 2014 UTC | revision 2157 by torben, Sat May 10 08:24:55 2014 UTC | |
---|---|---|
# | Line 21 public class Database { | Line 21 public class Database { |
21 | Connection conn; | Connection conn; |
22 | PreparedStatement saveStmt; | PreparedStatement saveStmt; |
23 | ||
24 | public Database(Properties conf) throws SQLException,IOException { | public Database(SafeProperties conf) throws SQLException,IOException { |
25 | this.conn = getConnection( conf ); | this.conn = getConnection( conf ); |
26 | ||
27 | String sql = "INSERT INTO fulddaekning.afstand_anden_rute_thn (orgId,orgPostnr, orgAdresse,orgGadeid,orgHusnr,orgHusnrBogstav,orgLatitude,orgLongitude,orgRute,id,postnr,adresse,gadeid,husnr,husnrbogstav,latitude,longitude,rute,afstand,`timestamp`) "+ | String sql = "INSERT INTO fulddaekning.afstand_anden_rute_thn (orgId,orgPostnr, orgAdresse,orgGadeid,orgHusnr,orgHusnrBogstav,orgLatitude,orgLongitude,orgRute,id,postnr,adresse,gadeid,husnr,husnrbogstav,latitude,longitude,rute,afstand,`timestamp`) "+ |
# | Line 190 public class Database { | Line 190 public class Database { |
190 | return list; | return list; |
191 | } | } |
192 | ||
193 | public Connection getConnection(Properties conf) throws SQLException, IOException { | public Connection getConnection(SafeProperties conf) throws SQLException, IOException { |
194 | ||
195 | String db_host = conf.getProperty("DB_HOST"); | String db_host = conf.getSafeProperty("DB_HOST"); |
196 | String db_user = conf.getProperty("DB_USER"); | String db_user = conf.getSafeProperty("DB_USER"); |
197 | String db_pass = conf.getProperty("DB_PASS"); | String db_pass = conf.getSafeProperty("DB_PASS"); |
198 | ||
199 | ||
200 |
|
ViewVC Help | |
Powered by ViewVC 1.1.20 |