iBatis with Spring: "JavaBeansDataExchange could not instantiate result class" Exception
The below exception trace occurs when trying to select records from database to create an instance of an entity or collection of entities. As a result of not providing default constructor on the entity class. I gave a sample entity implementation that has a constructor with string parameter and commented out default constructor. After running iBatis with Spring's framework, iBatis cannot find the default constructor and print the example stack trace. This is also pointing the basics of entity beans in Java EE, "Entity Beans must have a public default constructor". TRACE [2011-12-22 10:28:23,863] 00000522 DEBUG java.sql.Connection - {conn-100087} Preparing Statement: SELECT * FROM DEMO.SAMPLE_TABLE WHERE ID = ? [2011-12-22 10:28:23,863] 00000522 DEBUG java.sql.PreparedStatement - {pstm-100088} Executing Statement: SELECT * FROM DEMO.SAMPLE_TABLE WHERE ID = ? [2011-12-22 10:28:23,863] 00000522 DEBUG java.sql.PreparedStatement - {pstm-100088} Parameters: [1