db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Scott Eade <se...@backstagetech.com.au>
Subject Re: setting charSet via Torque.properties ?
Date Wed, 25 Feb 2004 12:16:35 GMT
E.Nebrat wrote:

> I use torque-3.1, + jdbc-odbc driver.
> I need to pass charSet property to the jdbc connection. I tried simply 
> to put such line in Torque.properties:
>    torque.dsfactory.mydatabase.connection.charset=Cp1251
> or even
>    torque.dsfactory.mydatabase.connection.charSet=Cp1251
> and I saw no reaction. Even when I put charset=CrazyCharsetName (if I 
> do so directly using jdbc connection, it causes exceptions) - no 
> reaction again.
> Is there some possibilty to do it?
> My Torque.properties:
> torque.database.default = utm
> torque.dsfactory.utm.adapter=msaccess
> torque.dsfactory.utm.factory=org.apache.torque.dsfactory.SharedPoolDataSourceFactory

> torque.dsfactory.utm.connection.driver=sun.jdbc.odbc.JdbcOdbcDriver
> torque.dsfactory.utm.connection.url=jdbc:odbc:utm-test
> torque.dsfactory.utm.connection.charset=Cp1251   // ???
> torque.dsfactory.utm.connection.user=
> torque.dsfactory.utm.connection.password=

Specifying the charset is dbms dependent.  for MySQL it is done as part 
of the connection url, for PostgreSQL it is picked up from the database 
itself.  You will need to determine how this might be accepted by the 
jdbc-odbc driver.  I wouldn't imagine you would want to do anything 
serious using the jdbc-odbc bridge anyway - it will be simpler in the 
long term to go ahead and use MySQL (or PostgreSQL or whatever) now.


Scott Eade
Backstage Technologies Pty. Ltd.

To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org

View raw message