Subject | java.util.Properties in getConnection? |
---|---|
Author | Rick Fincher |
Post date | 2004-01-15T21:40:59Z |
Hi All,
I'm going to put an item in the FAQ on using java.util.Properties when
getting a connection, as in Richard Drent's example below.
Has this always been supported in the driver, or at least since 1.0? Any
gotcha's I should mention?
Thanks,
Rick
Example:
Properties p = new Properties();
p.put("user","username");
p.put("password","userpassword");
p.put("lc_ctype","WIN1251");
Class.forName("org.firebirdsql.jdbc.FBDriver");
Connection conn =
DriverManager.getConnection("jdbc:firebirdsql:127.0.0.1/3050:C:\\Database\\d
bname.gdb",p);
I'm going to put an item in the FAQ on using java.util.Properties when
getting a connection, as in Richard Drent's example below.
Has this always been supported in the driver, or at least since 1.0? Any
gotcha's I should mention?
Thanks,
Rick
Example:
Properties p = new Properties();
p.put("user","username");
p.put("password","userpassword");
p.put("lc_ctype","WIN1251");
Class.forName("org.firebirdsql.jdbc.FBDriver");
Connection conn =
DriverManager.getConnection("jdbc:firebirdsql:127.0.0.1/3050:C:\\Database\\d
bname.gdb",p);