• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

jboss writing null rows in MySQL database

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all, if this question does not belong here please let me know.

I am trying to write an simple j2ee application runs on jboss, one of its tasks is to insert rows into a database table called COMMENT.
This table has an autoincremental key called id and I am trying to configure the insertion through jbosscmp-jdbc.

I am finding that all the rows that my application is wrting in the comment table are null.

The Transfer object related to the Comment table is called CommentTO, of which I copy the constructor below:

public CommentTO(int id, int showId, String description, int rate) {

super();
this.id = id;
this.idShow = showId;
this.description = description;
this.rate=rate;

logger.info("commentTO, this.id: "+this.id);
logger.info("commentTO, this.idShow: "+this.idShow);
logger.info("commentTO, this.description: "+this.description);
logger.info("commentTO, this.rate: "+this.rate);
}

The logger´s trace is showing me that CommentTO is receiving the correct values. However the values of idShow, description and rate are being lost.

I am puzzled, on one hand the row is being created, but then it is filled with null values (except for the id which is generated by the database) why is jboss refusing to write? Could it be a configuration problem?

Thanks a lot everyone
 
Bartender
Posts: 2661
19
Netbeans IDE C++ Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to JavaRanch.
Please check your private messages for a JavaRanch administrative matter.
 
javi perez
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jan Cumps wrote:Welcome to JavaRanch.
Please check your private messages for a JavaRanch administrative matter.



Updated to real name

BR
 
reply
    Bookmark Topic Watch Topic
  • New Topic