The following bug has been logged online:
Bug reference: 2884
Logged by: Ismail Cansiz
Email address: icansiz@gmail.com
PostgreSQL version: 8.2
Operating system: Centos Linux
Description: Bug in rs.getInt(colname) when JMV language is Turkish
Details:
I have run a query in java:
Here is some part of my java code:
----------------------------------------
sql="SELECT SEQ_ID FROM public.SEQUENCE_VALUE_ITEM WHERE
SEQ_NAME='ServerHitBin'";
rs=stmt.executeQuey(sql)
boolean gotVal1 = false;
if (rs.next()) {
val1 = rs.getInt("SEQ_ID");
gotVal1 = true;
}
rs.close();
if (!gotVal1) {
......
This code runs properl when JMV language is en_US.
But when JMV language is tr_TR, occured error.
When i changed the column name to lowercase
val1 = rs.getInt("seq_id");
runs properly.
Here error messages:
---------------------------------------------------
SELECT SEQ_ID FROM public.SEQUENCE_VALUE_ITEM WHERE SEQ_NAME='ServerHitBin'
Error was:Bu ResultSet içinde SEQ_ID sütun adı bulunamadı.
Exception: org.postgresql.util.PSQLException
Message: Bu ResultSet içinde SEQ_ID sütun adı bulunamadı.
---- stack trace
---------------------------------------------------------------
org.postgresql.util.PSQLException: Bu ResultSet içinde SEQ_ID sütun adı
bulunamadı.
org.postgresql.jdbc2.AbstractJdbc2ResultSet.findColumn(AbstractJdbc2ResultSe
t.java:2450)
org.postgresql.jdbc2.AbstractJdbc2ResultSet.getInt(AbstractJdbc2ResultSet.ja
va:2312)
org.ofbiz.minerva.pool.jdbc.ResultSetInPool.getInt(ResultSetInPool.java:517)