Link to home
Start Free TrialLog in
Avatar of ict-torquilclark
ict-torquilclark

asked on

Sum Formula Fields - This Field Cannot Be Sumarized

I am creating a report to analise telephone useage.

I have grouped the report by user and orderd by timestamp.

I have then used a formula to get the NEXT timestamp so as to discover the time the user entered and left this status and have then used DATEDIFF to get the number of seconds spent in the state.

I have then created a formula for each state to show the number of seconds spent if this record is for the state in question and 0 if not.

I now want to SUM the columns so i can have to total time spent in the state. I created a formula to do this and used "SUM({@Free}) but i get the error "This Field Cannot Be Sumarized".

I have checked and the field type is number. Can anybody suggest why/how to get to what i need.

If my description doesnt make sense I have attatched a previer of the report which should help.

Thanks for any suggestions :o)
Untitled.jpg
Avatar of peter57r
peter57r
Flag of United Kingdom of Great Britain and Northern Ireland image

What is @Free  (Code please)
If any of the formulas you mention use a summary or a function that is evaluated at print time then you can't insert a summary on them.

Youw ill probably need to use variables to accumulate the individual columns for your totals.
Agree with GJParker.

Another option is:
In this case you can create a Stored Procedure / View from your database and make a calculation as needed. Then use this Stored Procedure / VIew as your datasoure for your Crystal Report.
So, you can calculate all the fields as needed.

Hope it help.
Avatar of ict-torquilclark
ict-torquilclark

ASKER

@Free is a formula

IF {_AgentStatus.description} = "Free" Then
    {@Time In Status}
how would i use a variable?
From 'Field Explorer' (on the right side), right click on 'Formula Fields', and click 'New'.
Type the variable name and put the detail for it.
e.g.:
Variable name = TotFree --> contains: Sum({tblname.fieldFree}, {groupname})
Variable name = TotDialing --> contains: Sum({tblname.fieldDial}, {groupname})
.. and so-on.

hope it help.
ASKER CERTIFIED SOLUTION
Avatar of GJParker
GJParker
Flag of United Kingdom of Great Britain and Northern Ireland image

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