aspose file tools*
The moose likes Object Relational Mapping and the fly likes Invalid Column Name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Invalid Column Name" Watch "Invalid Column Name" New topic
Author

Invalid Column Name

pankaj semwal
Ranch Hand

Joined: Oct 07, 2008
Posts: 300
I am giving the following exception when i call this

S
2011/06/05 16:43:29 ERROR exceptionOccured(Slf4jSpyLogDelegator.java:103) - 3. ResultSet.getString(BRCD_CMPN_NO)
java.sql.SQLException: Invalid column name
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:269)
at oracle.jdbc.driver.OracleStatement.get_column_index(OracleStatement.java:6348)
at oracle.jdbc.driver.OracleResultSetImpl.findColumn(OracleResultSetImpl.java:1557)
at oracle.jdbc.driver.OracleResultSet.getString(OracleResultSet.java:1549)
at net.sf.log4jdbc.ResultSetSpy.getString(ResultSetSpy.java:1773)
at com.mchange.v2.c3p0.impl.NewProxyResultSet.getString(NewProxyResultSet.java:3342)
at org.hibernate.type.StringType.get(StringType.java:41)
at org.hibernate.type.NullableType.nullSafeGet(NullableType.java:184)
at org.hibernate.type.NullableType.nullSafeGet(NullableType.java:173)
at org.hibernate.type.AbstractType.hydrate(AbstractType.java:105)



Please tell me where i am wrong.
in Mkumar
Greenhorn

Joined: Sep 08, 2008
Posts: 20
Hey,

As per exception "java.sql.SQLException: Invalid column name", as of now i can suggest please verify the name of the databased fields available in the mapping file with database and pojo class.

I believe field name is mismatching some where in the mapping file/pojo with DB.

-Manoj
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Invalid Column Name