Lukas Eder created DERBY-6757:
---------------------------------
Summary: Driver.connect() returns null when using file-based URL
Key: DERBY-6757
URL: https://issues.apache.org/jira/browse/DERBY-6757
Project: Derby
Issue Type: Bug
Components: JDBC
Affects Versions: 10.11.1.1
Reporter: Lukas Eder
The following program can be used to reproduce this issue:
{code}
import java.sql.Driver;
import java.sql.DriverManager;
import java.util.Properties;
public class Test {
public static void main(String[] args) throws Exception {
Driver d = (Driver)
Class.forName("org.apache.derby.jdbc.ClientDriver").newInstance();
Properties properties = new Properties();
properties.setProperty("user", "TEST");
properties.setProperty("password", "TEST");
System.out.println(d.connect("jdbc:derby:C:/data/derby/test;create=true",
properties));
System.out.println(DriverManager.getConnection("jdbc:derby:C:/data/derby/test;create=true",
properties));
}
}
{code}
When run, the above program will output something like:
{monospace}
null
org.apache.derby.impl.jdbc.EmbedConnection@1226204845 (XID = 18681), (SESSIONID
= 1), (DATABASE = C:/data/derby/test), (DRDAID = null)
{monospace}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)