Hello.
I meet the difficulties with insert/update commands using Postgresql
JDBC driver.
Due to problems described previously at
> Re: value too long for type character varying(25) (http://archives.postgresql.org/pgsql-novice/2002-11/msg00166.php)
and
>Re: ParameterMetaData getPrecision() always zero? (http://archives.postgresql.org/pgsql-jdbc/2010-01/msg00077.php)
I have to perform an additional call to connection.getMetaData().getColumns()
in order to obtain the size of inserted/updated varchar field, and either
truncate the value at the client side, or make explicit truncations as shown
at (http://www.postgresql.org/docs/9.0/static/datatype-character.html)
The question is, are there any "standard" ways to avoid this excessive
call?
Have to say that a hand-made DB scheme caching is not the option.
Thank you in advance.
Pavel Milovantsev.