SQL Queries

Hi All,

I needed a help to decide which is the best practice to use the SQL queries.

In my Java Class i dont want to use the sql queries hard coded.

I dont want to go for a constant class also.

Would it be feasible to use the property file for this? ........

or i can go for some XML file.

Also i dont have much queries but for the maintainence prespective

i dont want to hard code the queries.

Please suggest .

[466 byte] By [java_jamboreea] at [2007-11-27 1:10:44]
# 1

Depends very much what you want to do with your queries.

I think you should look at http://www.hibernate.org/ this is a framework that will help you persist your objects. Don't be put off by the configuration.

I would advise against implementing your own dynamic mechanism as frameworks such as hibernate are tried and tested. Unless of course you want to do it as a general exercise.

ChristopherAngela at 2007-7-11 23:46:03 > top of Java-index,Java Essentials,Java Programming...