This one time, at band camp, Shannon Kendrick said:

SK>Is there a way to configure Castor to get a "java.sql.Connection" from the 
"javax.sql.DataSource" using a user ID and password? I have configured Castor to use 
JNDI to retrieve the javax.sql.DataSource, but my database (Oracle) requires a name 
and password to get a connection. I notice that Castor seems to use "getConnection()" 
rather than "getConnection(String, String)".

Shannon,

See http://castor.exolab.org/mapping.dtd and search for data-source.
In addition to the DTD, here is a sample database descriptor that
uses a DataSource:

    <database name="test" engine="postgresql" >
        <data-source class-name="org.postgresql.PostgresqlDataSource">
            <params server-name="wolf" database-name="castor_examples" 
port-number="5432" user="bws" password="bws" />
        </data-source>
        <mapping href="mapping.xml" />
    </database>

Bruce
--

perl -e 'print unpack("u30","<0G)U8V4\@4VYY9&5R\"F9E<G)E=\$\!F<FEI+F-O;0\`\`");'

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to