Re: possible JDBC 4 EOD bug??
Daniel John Debrunner wrote: My understanding was that this would be fixed by 6460994, which went into b97. Is there a link for that bug? It's not found at: http://bugs.sun.com/bugdatabase/index.jsp I'm not sure why its not visible there. Anyway, it seems that bug is not relevant to the issue you are seeing anyway, a misunderstanding on my part. I'm making a new bug report that I believe covers the issue you have hit. Vemund
Re: possible JDBC 4 EOD bug??
Daniel John Debrunner wrote: I'm trying to understand the expected behaviour of the assignment of columns from an EOD SQL @Select to a data class using JavaBeans style property accessors. I'm looking at section 19.1.5 User Class of JDBC 4.0. I have a class similar to the example but a little different. The difference is the private field name does not match the name of the JavaBean property, is that allowed? public class Person { private String myName; public void setName(String name) { this.myName = name; } public String getName() { return myName; } } If my select returns a column called 'NAME' then it does not map to the JavaBean property called 'name'. Instead the name of the column needs to map to the name of the private field, 'myName'. Then the field is set correctly but the setter is never used. Is this a bug, it seems like it? If I understand you correctly, I believe it is a known bug that I stumbled on myself a while ago. I thought it had been fixed in one of the latest Mustang builds but I haven't verified it myself. Which build have you been using? Vemund
Re: possible JDBC 4 EOD bug??
Vemund Ostgaard wrote: Daniel John Debrunner wrote: If my select returns a column called 'NAME' then it does not map to the JavaBean property called 'name'. Instead the name of the column needs to map to the name of the private field, 'myName'. Then the field is set correctly but the setter is never used. Is this a bug, it seems like it? If I understand you correctly, I believe it is a known bug that I stumbled on myself a while ago. I thought it had been fixed in one of the latest Mustang builds but I haven't verified it myself. Which build have you been using? Thanks, the description was a bit rushed because I had ony a little time before I needed to leave and I wanted to get the question out there. Do you have the bug number for the issue? I'm using b98. Thanks, Dan.
Re: possible JDBC 4 EOD bug??
It is definitely a bug Dan if it has not been resolved. If you feel the section in the spec could be clearer, please let me know as i have a small window to clarify this area. -lance Daniel John Debrunner wrote: Vemund Ostgaard wrote: Daniel John Debrunner wrote: If my select returns a column called 'NAME' then it does not map to the JavaBean property called 'name'. Instead the name of the column needs to map to the name of the private field, 'myName'. Then the field is set correctly but the setter is never used. Is this a bug, it seems like it? If I understand you correctly, I believe it is a known bug that I stumbled on myself a while ago. I thought it had been fixed in one of the latest Mustang builds but I haven't verified it myself. Which build have you been using? Thanks, the description was a bit rushed because I had ony a little time before I needed to leave and I wanted to get the question out there. Do you have the bug number for the issue? I'm using b98. Thanks, Dan.
Re: possible JDBC 4 EOD bug??
Lance J. Andersen wrote: It is definitely a bug Dan if it has not been resolved. If you feel the section in the spec could be clearer, please let me know as i have a small window to clarify this area. I think if the functionality is working then the spec is fine, I only got confused by the incorrect behaviour. Thanks, Dan.
Re: possible JDBC 4 EOD bug??
Daniel John Debrunner wrote: Vemund Ostgaard wrote: Daniel John Debrunner wrote: If my select returns a column called 'NAME' then it does not map to the JavaBean property called 'name'. Instead the name of the column needs to map to the name of the private field, 'myName'. Then the field is set correctly but the setter is never used. Is this a bug, it seems like it? If I understand you correctly, I believe it is a known bug that I stumbled on myself a while ago. I thought it had been fixed in one of the latest Mustang builds but I haven't verified it myself. Which build have you been using? Thanks, the description was a bit rushed because I had ony a little time before I needed to leave and I wanted to get the question out there. Do you have the bug number for the issue? My understanding was that this would be fixed by 6460994, which went into b97. I'm using b98. That should indicate that it didn't get fixed as part of that bug report. Vemund
Re: possible JDBC 4 EOD bug??
Vemund Ostgaard wrote: My understanding was that this would be fixed by 6460994, which went into b97. Is there a link for that bug? It's not found at: http://bugs.sun.com/bugdatabase/index.jsp Google shows nothing obvious for it. Thanks, Dan.
Re: possible JDBC 4 EOD bug??
Daniel John Debrunner wrote: Lance J. Andersen wrote: It is definitely a bug Dan if it has not been resolved. If you feel the section in the spec could be clearer, please let me know as i have a small window to clarify this area. I think if the functionality is working then the spec is fine, I only got confused by the incorrect behaviour. Actually reading on to later sections they only ever mention field within a data class, never using JavaBean setter and getters. Does this mean those sections (19.3.3, 19.3.1.4) only apply to fields? As an example, how would I use the ResultColumn Annotation with JavaBean setter and getter methods? Thanks, Dan.
Re: possible JDBC 4 EOD bug??
Daniel John Debrunner wrote: Daniel John Debrunner wrote: Lance J. Andersen wrote: It is definitely a bug Dan if it has not been resolved. If you feel the section in the spec could be clearer, please let me know as i have a small window to clarify this area. I think if the functionality is working then the spec is fine, I only got confused by the incorrect behaviour. Actually reading on to later sections they only ever mention "field within a data class", never using JavaBean setter and getters. Does this mean those sections (19.3.3, 19.3.1.4) only apply to fields? As an example, how would I use the ResultColumn Annotation with JavaBean setter and getter methods? Unfortunately no for ResultColumn as we needed to change the Annotation to be method and field, not just field for the Target type. We meant to support this but missed the window to update the annotation. For allColumnsMapped, this is indeed supposed to work with setters/getters. I will clarify this a bit better as this wording was added prior to including JavaBeans property support. Regards Lance Thanks, Dan.