You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Marcelo Magno <mm...@blumar.com.br> on 2003/07/02 03:57:37 UTC

Problems using MS JDBC Driver

	I am not managing the right way to put the MS SQL SERVER 2000 JDBC DRIVER to work, could anybody point me what I am doing wrong?

	
* This is the error from OJB:

 Error getting Connection from DriverManager with url (jdbc:microsoft:sqlserver://localhost:gestsol) and driver (com.microsoft.jdbc.sqlserver.SQLServerDriver): [Microsoft][SQLServer 2000 Driver for JDBC]Unable to connect.  Invalid URL.

* This is my repository_database:

       <jdbc-connection-descriptor
        jcd-alias="default"
        default-connection="true"
        platform="MsSQLServer"
   	  jdbc-level="2.0"
   	  driver="com.microsoft.jdbc.sqlserver.SQLServerDriver"
        protocol="jdbc"
        subprotocol="microsoft:sqlserver://localhost"
	  dbalias="gestsol"
        username="sa"
   	  password="******"
	  eager-release="false"
        batch-mode="false"
        useAutoCommit="0"
        ignoreAutoCommitExceptions="false"
   	 >

* This is the Full Error:

[org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl] INFO: Create new connection pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1827284[
  jcd-alias=default
  default-connection=true
  dbms=MsSQLServer
  jdbc-level=2.0
  driver=com.microsoft.jdbc.sqlserver.SQLServerDriver
  protocol=jdbc
  sub-protocol=microsoft:sqlserver://localhost
  db-alias=gestsol
  user=sa
  password=*****
  eager-release=false
  ConnectionPoolDescriptor={whenExhaustedAction=0, maxIdle=-1, maxActive=21, maxWait=5000, removeAbandoned=false, numTestsPerEvictionRun=10, testWhileIdle=false, minEvictableIdleTimeMillis=600000, testOnReturn=false, logAbandoned=false, removeAbandonedTimeout=300, timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
  batchMode=false
  useAutoCommit=AUTO_COMMIT_IGNORE_STATE
  ignoreAutoCommitExceptions=false
  sequenceDescriptor=<null>
]
[org.apache.ojb.broker.accesslayer.ConnectionFactoryAbstractImpl] ERROR: Error getting Connection from DriverManager with url (jdbc:microsoft:sqlserver://localhost:gestsol) and driver (com.microsoft.jdbc.sqlserver.SQLServerDriver)
[Microsoft][SQLServer 2000 Driver for JDBC]Unable to connect.  Invalid URL.
java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Unable to connect.  Invalid URL.
        at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source)


Thanks for all the help,
Marcelo Magno
 

Re: Problems using MS JDBC Driver

Posted by Thomas Quaile <to...@yahoo.com>.
Try this;

<jdbc-connection-descriptor
  platform="MsSQLServer"
  jdbc-level="3.0"
 
driver="com.microsoft.jdbc.sqlserver.SQLServerDriver"
  protocol="jdbc"
  subprotocol="microsoft:sqlserver"
dbalias="//gestsol:1433;DatabaseName=DATABASENAME;SelectMethod=cursor"
  username="sa"
  password="="******""
/>
--- Marcelo Magno <mm...@blumar.com.br> wrote:
> 	I am not managing the right way to put the MS SQL
> SERVER 2000 JDBC DRIVER to work, could anybody point
> me what I am doing wrong?
> 
> 	
> * This is the error from OJB:
> 
>  Error getting Connection from DriverManager with
> url (jdbc:microsoft:sqlserver://localhost:gestsol)
> and driver
> (com.microsoft.jdbc.sqlserver.SQLServerDriver):
> [Microsoft][SQLServer 2000 Driver for JDBC]Unable to
> connect.  Invalid URL.
> 
> * This is my repository_database:
> 
>        <jdbc-connection-descriptor
>         jcd-alias="default"
>         default-connection="true"
>         platform="MsSQLServer"
>    	  jdbc-level="2.0"
>    	 
>
driver="com.microsoft.jdbc.sqlserver.SQLServerDriver"
>         protocol="jdbc"
>        
> subprotocol="microsoft:sqlserver://localhost"
> 	  dbalias="gestsol"
>         username="sa"
>    	  password="******"
> 	  eager-release="false"
>         batch-mode="false"
>         useAutoCommit="0"
>         ignoreAutoCommitExceptions="false"
>    	 >
> 
> * This is the Full Error:
> 
>
[org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl]
> INFO: Create new connection
>
pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1827284[
>   jcd-alias=default
>   default-connection=true
>   dbms=MsSQLServer
>   jdbc-level=2.0
>  
> driver=com.microsoft.jdbc.sqlserver.SQLServerDriver
>   protocol=jdbc
>   sub-protocol=microsoft:sqlserver://localhost
>   db-alias=gestsol
>   user=sa
>   password=*****
>   eager-release=false
>   ConnectionPoolDescriptor={whenExhaustedAction=0,
> maxIdle=-1, maxActive=21, maxWait=5000,
> removeAbandoned=false, numTestsPerEvictionRun=10,
> testWhileIdle=false,
> minEvictableIdleTimeMillis=600000,
> testOnReturn=false, logAbandoned=false,
> removeAbandonedTimeout=300,
> timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
>   batchMode=false
>   useAutoCommit=AUTO_COMMIT_IGNORE_STATE
>   ignoreAutoCommitExceptions=false
>   sequenceDescriptor=<null>
> ]
>
[org.apache.ojb.broker.accesslayer.ConnectionFactoryAbstractImpl]
> ERROR: Error getting Connection from DriverManager
> with url
> (jdbc:microsoft:sqlserver://localhost:gestsol) and
> driver
> (com.microsoft.jdbc.sqlserver.SQLServerDriver)
> [Microsoft][SQLServer 2000 Driver for JDBC]Unable to
> connect.  Invalid URL.
> java.sql.SQLException: [Microsoft][SQLServer 2000
> Driver for JDBC]Unable to connect.  Invalid URL.
>         at
>
com.microsoft.jdbc.base.BaseExceptions.createException(Unknown
> Source)
> 
> 
> Thanks for all the help,
> Marcelo Magno
>  
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail:
> ojb-user-help@db.apache.org
> 


__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com