*
The moose likes JSP and the fly likes generate JSP from database Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "generate JSP from database" Watch "generate JSP from database" New topic
Author

generate JSP from database

Nuevo Juan
Greenhorn

Joined: Jun 07, 2005
Posts: 2
We look for tool to generate JSP from database schema.

Struts is good too.

tx
J.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30085
    
149

Nuevo,
Welcome to JavaRanch!

What do you want the JSP to display? The full database table or something else?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Pj Murray
Ranch Hand

Joined: Sep 24, 2004
Posts: 194
If I understand the task correctly, you want to be able to access data stored in a database via a Web client.

You've worked out that it probably means JSPs or JSP/Struts.

Both are excellent choices for thin Web clients, especially if the application is simply to access/update information stored in a database.

I'd image there's lots of business applications that require that and not much else.

I'd like to recommend the following:

-you'll be better off with a three tier rather than two tier application. I think you should have a data access tier based on Data Access Objects as your middle tier. DAOs are a core J2EE design pattern so you won't be doing anything unusual or unsustainable for long term maintenance even if another developer takes over later

-either Struts or plain JSPs are fine really. So go with your whatever skill level you can handle.

-you could try generating the entire application using a tool such as FireStorm/DAO. It can import you existing database schema and generate both a persistence tier (based on JDBC DAOs, EJB CMP, JDO, or Hibernate - I suggest using JDBC DAOs in this case) and can also generate your presentation tier (either Struts or plain JSPs - I suggest using plain JSPs in this case).

A simple application like this should really have a simple architecture. You should be able to download a tool like FireStorm/DAO and generate a working application in less than 30 minutes.

Some useful links:

DAOs

http://www.java.sun.com/blueprints/corej2eepatterns/Patterns/DataAccessObject.html

http://www.codefutures.com/java-dao/

FireStorm/DAO (generates both the DAOs AND JSPs)

http://www.codefutures.com/products/firestorm/


I hope this helps. Remember: keep it simple!


PJ Murray -
 
Consider Paul's rocket mass heater.
 
subject: generate JSP from database
 
Similar Threads
using jsp to generate excel file
Generating PDF and RTF file from jsp
reporting tool for java webapplications.
Need to generate a PDF file using JSP/Servlet getting data from the database.
html:options