Connected to a database in java at netbeans