You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2002/03/28 16:58:27 UTC

DO NOT REPLY [Bug 7580] New: - Wrong URL for jdbc connection

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7580>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7580

Wrong URL for jdbc connection

           Summary: Wrong URL for jdbc connection
           Product: Tomcat 4
           Version: 4.0.3 Final
          Platform: PC
               URL: http://jakarta.apache.org/tomcat/tomcat-4.0-doc/realm-
                    howto.html
        OS/Version: Other
            Status: NEW
          Severity: Blocker
          Priority: Other
         Component: Webapps:Documentation
        AssignedTo: tomcat-dev@jakarta.apache.org
        ReportedBy: konrad@hansin.com.pl


For establishing jdbc realm in server.xml file one need to type URL for 
connection with database. For MySQL due to Tomcat documentation it is:

connectionURL="jdbc:mysql://localhost/authority?user=dbuser;password=dbpass"
                                                          ^^^

But this one is wrong. Problem is with mark after user argument value, in place 
of "&" there is ";". First I changed it back to "&" but XML validation failed. 
So I typed "&amp;" what is of course "&" substitute in XML, and now everything 
works OK.

So the solution is to write statement with URL in this form:

connectionURL="jdbc:mysql://localhost/authority?user=dbuser&amp;password=dbpass"
                                                           ^^^^^

I hope it will help somebody.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>