Hi everyone,

The connection to SQL server in my machine is by default so username and
password are not needed to login. In this case, what should I specify in
<Resource.../> for username and password attributes? I tried not to include
them but got an error of "Login failed for user ''. The user is not
associated with a trusted SQL Server connection."

<Context path="/DBTest" docBase="DBTest"
        debug="5" reloadable="true" crossContext="true">
  <Resource name="jdbc/EmployeeDB" auth="Container" type="
javax.sql.DataSource" username="<user name>" password="<pwd>"
  driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver"
  url="jdbc:sqlserver://localhost:1433;databaseName=EmployeeDB"
  maxActive="8" maxIdle="4"/>
</Context>

Thanks.

Reply via email to