the standard way is to martial the data in groovy script that are
called out(the new way) in a screen definition. you can find many
examples of this in the code.
The martialed data is then defined and passed to the screen where you
define screenlets to define layout.
I don't use SQL directly but define a entityview.
Note: I sent this to the user ML so others that may approach this
differently can respond.
however if you want personalized help, I will be glad to consult for a
fee with you.
giridhar mungi sent the following on 10/7/2012 10:03 PM:
Hi Freeman,
Good day to you.
my name is giridhar.Thanks for accepting for my connection request in
linkedin. i have seen ur mail id in linkedin.
I have doubt in Sql.please help me if you know.
*TableName:stores*
*storeid date price paymenttype*
101 Oct-01 26 Creditcard
101 Oct-01 25 Creditcard
101 Oct-01 25 Cash
101 Oct-01 24 Cash
101 Oct-01 33 Cash
101 Oct-01 35 Cash.
This is the sample data.I want to display the total creditcard amount and
total cash amount individually per date and storeid.
if we want to display the creditcard,we can give like *select
storeid,date,sum(price) as creditcardtotal from stores where
paymenttype='creditcard'* *group by storeid,date*;
if we want to display the cash total,we can give like *select
storeid,date,sum(price) as cashtotal from stores where
paymenttype='cash'* *group
by storeid,date*;
*How to display the total amounts of credit card and cash per storeid and
date in a single query like,
storeid date totalcreditcardamount totalcashamount
*please help me sir.*
*
Thanks& Regards,,
giridhar.