I'm trying to migrate some DB access from ibatis to mybatis 3.1.1 and I'm
having a lot of trouble with some selects. In one case the object would be
partially populated with data from the select, but not all of the fields
that were selected and mapped were getting set on the object. No
exceptions, it just partially filled the object. The resultMap contained
an association, and I thought that might be the cause so I removed that and
it still wasn't filling in data I expected to. I then stripped the select
and the resultmap down to just a couple fields and now all of the ones in
the stripped down select are being populated correctly.
In another case I've got a select that's returning a null object even
though it should find data in the database. I turned on debug logging and
copied and pasted the query into mysql and I'm seeing a result just as I
expect.
Either I'm doing something fundamentally wrong, or I'm stumbling on a
bug... (After the mybatis-spring issue I had with multiple databases, I
suspect this is quite possible)
About 1/3rd of my unit tests are passing right now. Some of the problems
may be caused by mistakes I made in the porting to mybatis, but the first
few I've looked at have had me scratching my head as described.