Attribute name/value pairs are converted into properties and added
to the properties provided in the connection call. If no properties are provided
in the connection call, a properties set is created that contains only the
properties obtained from the database connection URL.
import java.util.Properties;
Connection conn = DriverManager.getConnection(
"jdbc:derby:sampleDB;create=true");
/* setting an attribute in a Properties object */
Properties myProps = new Properties();
myProps.put("create", "true");
Connection conn = DriverManager.getConnection(
"jdbc:derby:sampleDB", myProps);
/* passing user name and password */
Connection conn = DriverManager.getConnection(
"jdbc:derby:sampleDB", "dba", "password");