How to connect Tomcat 4.1 to MS SQL2000?

Posted on 2006-04-04
Last Modified: 2010-04-01
<Context path="/boa"
         reloadable="true" >

<Realm className="org.apache.catalina.realm.JDBCRealm" debug="99"
userTable="users" userNameCol="user_name" userCredCol="USER_PASS" userRoleTable="user_roles"
roleNameCol="ROLE_NAME" />

Above is the tag I have in my server.xml to define the site and the Realm to connect to MS SQL2000.  I have put the driver jar file into /server/lib folder of Tomcat but I keep getting the error below, any reason for it? I have made sure I use the JDBCRealm that comes with Tomcat.

INFO: Initializing Coyote HTTP/1.1 on http-8080
Starting service Tomcat-Standalone
Apache Tomcat/4.1.31
        at org.apache.catalina.realm.JDBCRealm.start(
        at org.apache.catalina.core.StandardContext.start(
        at org.apache.catalina.core.ContainerBase.start(
        at org.apache.catalina.core.StandardHost.start(
        at org.apache.catalina.core.ContainerBase.start(
        at org.apache.catalina.core.StandardEngine.start(
        at org.apache.catalina.core.StandardService.start(
        at org.apache.catalina.core.StandardServer.s
tThe application exiteda
        at org.apache.catalina.startup.Catalina.start(
        at org.apache.catalina.startup.Catalina.execute(
        at org.apache.catalina.startup.Catalina.process(
        at sun.reflect.NativeMetC:\BOA\Tomcat\bin>
Question by:fylix0000
    LVL 29

    Accepted Solution

    Can you connect to the database using a JSP? This would check that the database permissions are correctly set for the user that you are using. and that the password is correct
    LVL 19

    Expert Comment

    It is also possible that database is not listening at port 1433 for incoming connection ( will have if somebody has dorked around the SQL server settings)..
    LVL 8

    Expert Comment

    What data types are you using? Are you using blobs anywhere?


    Author Comment

    The database I have uses just varchar, bigint, smallint, tinyint, dont think I have blobs anywhere.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    Running Java Servlet inside Eclipse Luna 6 127
    JSP + json + data structure 10 376
    grep code 4 134
    using if condition without JSTL 2 99
    Outlook Free & Paid Tools
    If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now