[Opensource] Expresso - how to change the date format question
milend
milend at ansco.com
Mon Sep 9 10:05:52 PDT 2002
Hi,
I'm trying to change the date format used in Expresso from "yyyy-mm-dd" to "dd/mm/yy".
I already have in my expresso-config.xml,jdbc section
the next 4 parameters:
dateSelectFormat="dd/MM/yy"
dateUpdateFormat="dd/MM/yy"
dateTimeSelectFormat="dd/MM/yy"
dateTimeUpdateFormat="dd/MM/yy"
Are there any other settings I nedd to change ?
I have no problems to add/update a record using DBMaint for example.
But I get errors when I'm using DBMaint to list records:
"Nested exception message:(com.ansco.accounting.gl.dbobj.MyDBObject)
Unable to parse a date value from field 'date' which contained
'2002-01-01' using pattern 'dd/MM/yy'"
The problem is that date values in my myDBObject are in format "yyyy-mm-dd"
and cannot be parsed using the new format "dd/mm/yy".
And I can figure out why DBConection.getString(i) method still returns
date field values in format "yyyy-mm-dd". (I expect them in the new format "dd/mm/yy")
Any help will be greatly appresiated!
Than you in advance!
I'm using Expresso 4.1 ea2
Milen
------------------------------------
here is a part of my expresso-config.xml
<context name="DB start">
<description>DB start </description>
<jdbc
driver="org.postgresql.Driver"
url="jdbc:postgresql://192.168.5.100:5432/dbstart"
connectFormat="3"
login="postgres"
password="postgres"
cache="y"
dateSelectFormat="dd/MM/yy"
dateUpdateFormat="dd/MM/yy"
dateTimeSelectFormat="dd/MM/yy"
dateTimeUpdateFormat="dd/MM/yy"
/>
<type-mapping>
<java-type>INTEGER</java-type>
<db-type>INTEGER</db-type>
</type-mapping>
<type-mapping>
<java-type>FLOAT</java-type>
<db-type>FLOAT8</db-type>
</type-mapping>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.jcorporate.com/pipermail/opensource/attachments/20020909/243fc9a6/attachment-0002.htm
More information about the Opensource
mailing list