[Biojava-l] BioSQL
Thomas Down
td2@sanger.ac.uk
Tue, 27 Aug 2002 12:28:40 +0100
On Tue, Aug 27, 2002 at 04:38:29PM +0900, Yasumasa Shigemoto wrote:
>
> I'm trying BioSQL but I don't understand the following 'biodatabases'.
>
> public BioSQLSequenceDB(java.lang.String dbURL,
> java.lang.String dbUser,
> java.lang.String dbPass,
> java.lang.String biodatabase,
> boolean create)
>
> What is specified for the biodatabase for example?
>
> I try "SeqDumper.java" but I get the Exception.
>
> $ java biosql.SeqDumper "jdbc:postgresql:biosqldb" "postgres" "postgres"
> ""
> Exception in thread "main" java.sql.SQLException: No suitable driver
Hi...
This is a limitation in JDBC -- you need to explicitly load the database
driver(s) you're using. There are several ways to do this. The one
I tend to use is to set the "jdbc.drivers" system property. For
examples:
java -Djdbc.drivers=org.postgresql.Driver biosql.SeqDumper "jdbc:postgresql:biosqldb" "postgres" "postgres" ""
Note that you still need to add the relevant JAR file as well.
A lot of people have been having this problem. Future versions
may include code to test automatically for some common database
drivers. However, this isn't an ideal solution, since the BioSQL
code tries to be database-independent.
Hope this helps,
Thomas.