yups ryan even  iam using the same method for JDBC calls and i think that this provides quite a lot program modularity.
even i want to know whether is there a much better approach for JDBC calls.
 

Vikramjit singh,
eAngel Team,
Global Tele-systems Ltd.
Ph. 7612929-3140

-----Original Message-----
From: Ryan Cornia [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 18, 2001 6:56 AM
To: [EMAIL PROTECTED]
Subject: Where do YOU put JDBC calls?

I'm wondering what people are considering best practices for JDBC calls?
 
I have been writing beans that wrap a database table, and include functions "select", "insert", "delete". These functions either load the bean, insert the bean values in the database, or delete the record from the database. In all of these functions, I pass in a database connection from the action. (Or whatever else is calling the bean.)
 
ie- public boolean select(Connection cn1, String primaryKey)
 
How are others doing it? I think this is a good approach, but want to see if someone has come up with something better.
 
Thanks,
Ryan
 

Reply via email to