General J2EE: Data Access Object (DAO) pattern
Can anybody provide some real-world implementation examples of the DAO pattern?
- Posted by: Sean Sullivan
- Posted on: October 13 2002 17:19 EDT
I already looked at Sun's Java Petstore. They use DAO only for read-only database queries.
Check at this Prentice Hall Book at
If you don't want to buy it, just download the sample code and look at their DAO sample in chapter 4. (Follow Download Link on left).
You can use a tool like FireStorm/DAO to generate DAO source code for your own database. There's a free download that lets you generate code for 5 tables and this will give you full working examples of DAO source code. You can download it from:
http://freesourceutilityhelp.googlepages.com/data-access-object-dao-pattern.html a nice and good blog. thanks.