You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by Mohd Amin <pr...@hotmail.com> on 2003/03/17 12:31:36 UTC

A database-based forms reports tool

Hi

Thinking about creating a forms and reporting tool, something like Oracle Forms/Reports/Discoverer which enables the user to select a database then wade through it's tables and create turbine modules for the tables. The modules consists of  list, add, edit, search forms. Oracle uses Business Component 4 Java(BC4J) for it. If the tables are linked using foreign keys then the forms should also have master details with the coressponding tables.

An addition would be to have a reporting tool for the tables and ways to ustomize the output of the data.

The idea is there but looking for ways to implement it using turbine and torque. Are there any projects using turbine currently doing this?

Amin

Re: A database-based forms reports tool

Posted by Rajeev Kaul <Ra...@customercaresolutions.com>.
It will be more fruitful to tell us the specific reasons why you chose
Turbine over Struts.

A few years back, when I had to make a choice between the two, I chose
Turbine for the following reasons:

1. Flexibility to choose between different presentation formats:  Velocity,
JSP, etc.
2. The service framework.
3. Vast array of ready-to-use services - security, xml-rpc, jndi, logging,
etc.
4. Object relational database - torque
5. A set of useful utilities - exception handling, form validation, email,
parameter parser, etc.

However, when I look at Struts now, I do not see Turbine having much of an
edge over it. Struts now allows you the option to use Velocity as a
template. Its no longer tied to JSPs only. You can use OJB as an OR tool
with it. It also has a large set of useful utilities including form
validation.  Plus it has excellent docs and a large user base.

Frankly, in my opinion you could not go much wrong in choosing either one as
a framework for developing web-applications.


----- Original Message -----
From: "Eric Emminger" <er...@ericemminger.com>
To: "Turbine Users List" <tu...@jakarta.apache.org>
Sent: Friday, March 21, 2003 10:08 AM
Subject: Re: A database-based forms reports tool


> Amin
>
> > What do u'll think bout struts in respect to turbine?
>
> Before deciding to use Turbine, I looked at *many* options, including
> Struts. I chose Turbine because it seems to be the best all-around. So,
> I think Turbine is better than Struts, at least for my applications.
>
> Eric
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: A database-based forms reports tool

Posted by Eric Emminger <er...@ericemminger.com>.
Amin

> What do u'll think bout struts in respect to turbine?

Before deciding to use Turbine, I looked at *many* options, including 
Struts. I chose Turbine because it seems to be the best all-around. So, 
I think Turbine is better than Struts, at least for my applications.

Eric


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


RE: complex objects in forms

Posted by Chris K Chew <ch...@fenetics.com>.
> From: Colin Chalmers [mailto:colin.chalmers@maxware.nl]
>
> I've got a problem where I have to have many objects of the same
> type in one
> page.

Hey Colin.

It has been a while since I did this, but the following gives the general
idea.

1.  Make sure you use get/setQueryKey() instead of .Default in your screen
template when mapping each object.  This way you get field names like
"<groupkey><querykey><namekey>", ie "TheGroup142firstname" or
"TheGroup123firstname".  Otherwise, the default would make every firstname
field "TheGroup_01firstname" and you would lose the all the objects in your
form but one.

2.  Put a hidden string field "querykey" for each object in the form.  The
value of this should be the getQueryKey() for each object in the form.  Each
of these fields need to have the same name.

3.  In your action, call String[] querykeys =
data.getParameters().getStrings("querykey").  This captures a list of
querykeys contained in the form.

4.  Also in your action, cycle through each member in the querykeys array
calling intake.get("TheGroup", querykey) and performing your validation and
persistence for that object.

I hope this helps,

Chris


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: complex objects in forms

Posted by Colin Chalmers <co...@maxware.nl>.
On the topic of Intake :-)

I've got a problem where I have to have many objects of the same type in one
page.
Is anyone doing this and can give some tips as to how to achieve it? I need
to access the page with (mostly)  default values, number of objects is
variable but of same type.

Up until now I've only had to deal with say one or a couple of differing
objects in one page. Which I've got my head round pretty well.

Colin

----- Original Message -----
From: "Chris K Chew" <ch...@fenetics.com>
To: "Turbine Users List" <tu...@jakarta.apache.org>
Sent: Friday, March 21, 2003 6:20 PM
Subject: RE: complex objects in forms


> > From: Jeffery Painter [mailto:painter@kiasoft.com]
> >
> > This is it exactly... your example for Customer -> shippingAddress is
> > exactly what I'm after... our customer records can have many
> > addresses and
> > was trying to figure out a good way to seperate this out.
> >
> > It will take me a day or so to wrap my head around this methodology but
> > I'm sure it will be worth it.
> >
> > I would be willing to write up a some documentation of my experience
> > combined with  the facade technique to add to the turbine docs
> > when I'm finished.
>
> Hi Jeff.
>
> Yeah, we use the facade trick all the time.
>
> Unbelievably, I didn't have a section for this on the Wiki User's Guide
> Outline.  I just added one in the Intake section, hopefully you will add
> your knowledge as you progress:
>
> http://nagoya.apache.org/wiki/apachewiki.cgi?JakartaTurbine2UsersGuide
>
> Thanks,
>
> Chris
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


RE: complex objects in forms

Posted by Chris K Chew <ch...@fenetics.com>.
> From: Jeffery Painter [mailto:painter@kiasoft.com]
>
> This is it exactly... your example for Customer -> shippingAddress is
> exactly what I'm after... our customer records can have many
> addresses and
> was trying to figure out a good way to seperate this out.
>
> It will take me a day or so to wrap my head around this methodology but
> I'm sure it will be worth it.
>
> I would be willing to write up a some documentation of my experience
> combined with  the facade technique to add to the turbine docs
> when I'm finished.

Hi Jeff.

Yeah, we use the facade trick all the time.

Unbelievably, I didn't have a section for this on the Wiki User's Guide
Outline.  I just added one in the Intake section, hopefully you will add
your knowledge as you progress:

http://nagoya.apache.org/wiki/apachewiki.cgi?JakartaTurbine2UsersGuide

Thanks,

Chris


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


RE: complex objects in forms

Posted by Jeffery Painter <pa...@kiasoft.com>.
This is it exactly... your example for Customer -> shippingAddress is 
exactly what I'm after... our customer records can have many addresses and 
was trying to figure out a good way to seperate this out.

It will take me a day or so to wrap my head around this methodology but 
I'm sure it will be worth it.

I would be willing to write up a some documentation of my experience 
combined with  the facade technique to add to the turbine docs when I'm finished.

Thanks

Jeff Painter
painter@kiasoft.com



On Fri, 21 Mar 2003, Chris K Chew wrote:

> Hi Jeff.
> 
> It sounds like Intake will work well for the situation.
> 
> One trick that we use often is to create a complex Facade class to which
> intake maps.  You can store the facade object in user.setTemp() through a
> wizard, or have a big form that maps to the Facade, which maps to your
> target objects.  Search turbine-user for the thread "intake: mapping the
> group against 2 objects possible?" on 02/19/2003 for a bigger explanation.
> 
> Good luck,
> 
> Chris
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


RE: complex objects in forms

Posted by Chris K Chew <ch...@fenetics.com>.
Hi Jeff.

It sounds like Intake will work well for the situation.

One trick that we use often is to create a complex Facade class to which
intake maps.  You can store the facade object in user.setTemp() through a
wizard, or have a big form that maps to the Facade, which maps to your
target objects.  Search turbine-user for the thread "intake: mapping the
group against 2 objects possible?" on 02/19/2003 for a bigger explanation.

Good luck,

Chris


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: complex objects in forms

Posted by Jeffery Painter <pa...@kiasoft.com>.
well, maybe intake is the solution :) pardon my ranting... I'll see if it 
does the trick for me.

Jeff

On Fri, 21 Mar 2003, Jeffery Painter wrote:

> 
> I've been beating my head on this for a day now and searched through many 
> of the docs for the most elegant way to solve a problem I'm having.
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


complex objects in forms

Posted by Jeffery Painter <pa...@kiasoft.com>.
I've been beating my head on this for a day now and searched through many 
of the docs for the most elegant way to solve a problem I'm having.

I have a Customer object, which has many other objects tied to it. I want 
to allow the screen to capture as much of the data as possible on the 
initial insert screen before pushing the user to "Next screen"...

I was successful in doing New Customer, add customer object to the 
context, return step 2 of adding new customer etc, but I would rather get 
the bare necessities all on the first screen, allow the user to come back 
and update the object as needed later on.

I read on one thread a suggestion to use castor to create a map but this 
seems like double work.. I could just as easily extract each and every 
form element from the RunData parameters and create the objects manually 
myself, but this seems like a lot of redundant coding.

I love the simplicity of the action call

    public void doInsert(RunData data, Context context)
        throws Exception
    {

        Product entry = new Product();
        data.getParameters().setProperties(entry);
        entry.setNew(true);
        entry.save();
    }

but when Product needs to map additional data, like a color and size 
matrix that I'm trying to do, this simple method doesn't seem possible to 
gather on one screen.

I've been using turbine for several months now and love it but would like 
any help in pointing me in the right direction to do this.

I have not tried using Intake for form validation at this point.. the app 
is still in development and fields are still volital.. I don't think it 
would help in this case anyway.


Kind regards,

Jeff Painter
painter@kiasoft.com



---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: A database-based forms reports tool

Posted by "Henning P. Schmiedehausen" <hp...@intermeta.de>.
"Mohd Amin" <pr...@hotmail.com> writes:

>In the midst of learning Struts, just to compare with turbine before really
>adopting a framework and building on top of it.

>What do u'll think bout struts in respect to turbine?

Better docs.

	Regards
		Henning

-- 
Dipl.-Inf. (Univ.) Henning P. Schmiedehausen          INTERMETA GmbH
hps@intermeta.de        +49 9131 50 654 0   http://www.intermeta.de/

Java, perl, Solaris, Linux, xSP Consulting, Web Services 
freelance consultant -- Jakarta Turbine Development  -- hero for hire

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: A database-based forms reports tool

Posted by Mohd Amin <pr...@hotmail.com>.
In the midst of learning Struts, just to compare with turbine before really
adopting a framework and building on top of it.

What do u'll think bout struts in respect to turbine?

Amin
----- Original Message -----
From: "Eric Emminger" <er...@ericemminger.com>
To: "Turbine Users List" <tu...@jakarta.apache.org>
Cc: <pr...@hotmail.com>
Sent: Thursday, March 20, 2003 11:11 PM
Subject: Re: A database-based forms reports tool


> Amin
>
> > Thinking about creating a forms and reporting tool, something like
> > Oracle Forms/Reports/Discoverer which enables the user to select a
> > database then wade through it's tables and create turbine modules for
> > the tables. The modules consists of  list, add, edit, search forms.
> > Oracle uses Business Component 4 Java(BC4J) for it. If the tables are
> > linked using foreign keys then the forms should also have master
> > details with the coressponding tables.
>
> This would be great.
>
> > An addition would be to have a reporting tool for the tables and ways
> > to ustomize the output of the data.
> >
> > The idea is there but looking for ways to implement it using turbine
> > and torque. Are there any projects using turbine currently doing
> > this?
>
> I don't know of any projects, but they may exist. To implement this, you
> would probably use the table maps in Torque.
>
> I'd be happy to talk about this more.
>
> Eric
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org


Re: A database-based forms reports tool

Posted by Eric Emminger <er...@ericemminger.com>.
Amin

> Thinking about creating a forms and reporting tool, something like
> Oracle Forms/Reports/Discoverer which enables the user to select a
> database then wade through it's tables and create turbine modules for
> the tables. The modules consists of  list, add, edit, search forms.
> Oracle uses Business Component 4 Java(BC4J) for it. If the tables are
> linked using foreign keys then the forms should also have master
> details with the coressponding tables.

This would be great.

> An addition would be to have a reporting tool for the tables and ways
> to ustomize the output of the data.
> 
> The idea is there but looking for ways to implement it using turbine
> and torque. Are there any projects using turbine currently doing
> this?

I don't know of any projects, but they may exist. To implement this, you 
would probably use the table maps in Torque.

I'd be happy to talk about this more.

Eric


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org