Saturday, May 12, 2012

JDBC isn't a good solution for database programming

Now I realize that JDBC is not a good solution in writing a program that involve database because there are a lot of code need to be done. Basically I just copy and paste the redundant code and reuse back for other purpose. So a new idea coming out to hide this redundant code by creating a wrapper class.

Brilliant right? Not really because this only help a portion of my code. There are more tedious one following up next.

Another issue was I need to handle the association on my own. Meaning that when object_A is referencing object_B like the example shown below:

public class Object_A {
    public Object_B objB;


There are many more code I need to go if my table field consist of 20 fields. This is so terrible.

No comments: