You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gary D. Gregory (Jira)" <ji...@apache.org> on 2025/01/07 14:07:01 UTC
[jira] [Updated] (BEANUTILS-383) `select name as foo_name' - > RowSetDynaClass detects false column name which causes java.sql.SQLException: Column 'name' not found.
[ https://issues.apache.org/jira/browse/BEANUTILS-383?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Gary D. Gregory updated BEANUTILS-383:
--------------------------------------
Fix Version/s: 2.0.0-M2
(was: 2.0.0-M1)
> `select name as foo_name' - > RowSetDynaClass detects false column name which causes java.sql.SQLException: Column 'name' not found.
> -------------------------------------------------------------------------------------------------------------------------------------
>
> Key: BEANUTILS-383
> URL: https://issues.apache.org/jira/browse/BEANUTILS-383
> Project: Commons BeanUtils
> Issue Type: Bug
> Affects Versions: 1.8.3
> Environment: gentoo linux 64 bit
> Reporter: Kfir Ozer
> Priority: Major
> Fix For: 2.0.0-M2
>
>
> Hello.
> If i have the following query:
> 'select game.name as game_name from games'
> and i use RowSetDynaClass to fetch a list of DynaBeans from the result set, i get the following error:
> ERROR c.x.xpofacebook.mysql.MysqlDb - stack trace: java.sql.SQLException: Column 'name' not found.
> it seems that the RowSetDynaClass fetches the column names as their original names and does not consider column names modification with the 'as' keyword.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)