> hi, i'm starting in Struts, and am reading the tutorials in the struts > site about building applications with it, and i was thinking if there is > any easy tutorial about database access using struts, so i can start > more rapidly with it (and my boss doesn't get mad at me while > convincing him to use struts in the new project we are starting ;)
Been there... :) And discovered that there really isn't any "database access using Struts". Your data access solution shouldn't have anything to do with Struts. It should be usable from a Struts Action, from a Swing app, from a console app, etc. Personally, I implemented the "Data Access Object" pattern as shown in the J2EE Blueprints document. That may be overkill for a simple app where you might put JDBC code directly in the Action class. Or something in between. The problem with the existing examples is that they have comments such as, "In a real-world application, we wouldn't do this, but for the purposes of this example..." And nobody ever shows you how you WOULD do it in the real world, because it's messy and complicated and depends on your data structures and rules. So if you haven't determined how you're going to access your database, do that first, separately, before you try to access your database from Struts. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management