RE: Connection to SQL Server 2005 from Jboss 4.03



It looks like your class name and URL are correct, so I would suggest checking:

1) ensure that your SQL Server is setup to access SQL authentication
2) ensure you SQL Server is listening on TCP/IP

The easiest way to test this is to create a UDL and then try to connect to your SQL Server using a connection string of the form:

tcp:servername

and using SQL Authentication

Evan

--------------------
From: "leslie_tighe@xxxxxxxxx" <leslie_tighe@xxxxxxxxx>
Subject: Connection to SQL Server 2005 from Jboss 4.03

Hello,

I am trying to setup a datasource in Jboss 4.03 with Sql server 2005
using the new Sql server 2005 jdbc driver.

I have the following parameters in the mssql_ds.xml file:

<connection-url>jdbc:sqlserver://localhost;databaseName=DIAMELLE;selectMethod=cursor</connection-url>

<driver-class>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver-class>

However, keep getting the following error, which indicates that the
login failed, but the user id and password are correct.


2006-02-27 18:43:55,953 DEBUG
[org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory]
Checking driver for URL:
jdbc:sqlserver://localhost:1433;databaseName=DIAMELLE;selectMethod=cursor
2006-02-27 18:43:55,953 DEBUG
[org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory]
Driver not yet registered for url:
jdbc:sqlserver://localhost:1433;databaseName=DIAMELLE;selectMethod=cursor
2006-02-27 18:43:56,015 DEBUG
[org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory]
Driver already registered for url:
jdbc:sqlserver://localhost:1433;databaseName=DIAMELLE;selectMethod=cursor
2006-02-27 18:43:56,062 WARN
[org.jboss.resource.connectionmanager.JBossManagedConnectionPool]
Throwable while attempting to get a new connection: null
org.jboss.resource.JBossResourceException: Could not create connection;
- nested throwable: (com.microsoft.sqlserver.jdbc.SQLServerException:
Login failed for user 'idmuser'.)
at
org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:164)
at
org.jboss.resource.connectionmanager.InternalManagedConnectionPool.createConnectionEventListener(InternalManagedConnectionPool.java:519)
at
org.jboss.resource.connectionmanager.InternalManagedConnectionPool.getConnection(InternalManagedConnectionPool.java:208)
at
org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.getConnection(JBossManagedConnectionPool.java:529)

Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Login
failed for user 'idmuser'.
at
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown
Source)
at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown
Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.logon(Unknown
Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(Unknown
Source)
at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(Unknown
Source)
at
org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:154)



Any thoughts on how I can resolve this?

Thanks
Leslie




--

This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm

Note: For the benefit of the community-at-large, all responses to this message are best directed to the newsgroup/thread from which they originated.

.



Relevant Pages

  • Driver corrupts prepared statements in pool.
    ... This test case demonstrates a bug in the Microsoft SQL Server 2005 JDBC ... cause an exception the next time it is used. ... Microsoft SQL Server 2005 JDBC driver 1.0.809.102 ... // A connection will NOT work properly until it has been ...
    (microsoft.public.sqlserver.jdbcdriver)
  • Re: Connection getMetaData() does not throw SQL Exception
    ... The reason the getMetaDatacall doesn't fail is because all the ... the driver object. ... We support MySQL, Oracle, and SQL Server. ... The java code does not use connection pooling. ...
    (microsoft.public.sqlserver.jdbcdriver)
  • RE: Padding using Type 4 Drivers
    ... | Does anybody know what configuration a SQL Server DB has which effects ... Whenever you make a connection to SQL Server, ... your connection will receive a default set of ANSI settings based on the ... Are you using the Microsoft JDBC driver or a third-party driver?. ...
    (microsoft.public.sqlserver.jdbcdriver)
  • Re: Error "SQL Server does not allow remote connections"
    ... The application could not connect to the sql server db. ... network is blocking the connection. ... SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 ... integratedSecurity, SqlConnection owningObject) +737554 ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Connection from remote computer to network SQL Server
    ... There is no firewall on the W2K machine acting as the SQL server. ... I tried making the SQL machine a "trusted" on the router. ... connection works. ... To find the IP address of your computer inside the network, ...
    (microsoft.public.access.adp.sqlserver)

Loading