Link to home
Start Free TrialLog in
Avatar of chinnaji
chinnaji

asked on

How to look up subtotals from a view into a form??

Hi Experts,

Is it possible to retrieve/look up sub totals from a view into a form??
===========================================
For Example I have a view with the following values:

User1     10   20   30   40   50  
             10   20   30   40   50
subtotal: 20   40   60   80   100

User2            20         40   50  
             10   20   30   40   50
subtotal: 10   40   30   80   100
===========================================

In Form-A I would like to look up the subtotals for
user1 : subtotal: 20   40   60   80   100

and in Form-B subtotals for
user2 : subtotal: 10   40   30   80   100.

Is this possible??? If so I need your help.

On an other form I am using the following formula to look up data from a view
@Unique(@Text(@DbColumn( "" : "NoCache" ; "" ; "CP1\\CP1-YES1" ; 1))) but I do not know how to look up subtotals.

Thanks in advance for your help.

Avatar of RanjeetRain
RanjeetRain

You LotusScript to manually generate the subtotals.
Use NotesViewNavigator.  If you create a NotesViewNavigator that includes the view entries you want, then it will include catgeory entries and the final totals view entry.  You can then use the NotesViewEntry.columnValues to retrieve the totals.

you can also use @DbCOlumn, but that is much more of a pain inthe neck.  @DbLookup does not return totals, but @DbCOlumn does.  Problem is, that returns all values in that column in the view, and you then have to piece it back out.
Besides, with @DBColumn, you run into the rick of crossing 64K limit.
Avatar of chinnaji

ASKER

I have never used a notes View Navigator .. Can you please provide me an example for NotesViewEntry.columnValues.??
ASKER CERTIFIED SOLUTION
Avatar of qwaletee
qwaletee

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial