×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Comparing scores and summarising into a table.

Comparing scores and summarising into a table.

Comparing scores and summarising into a table.

(OP)
Hi there,

I was hoping to re-use a solution provided by Lbass on thread thread767-1794186: Ability to use a formula on a specified column on a crosstab

This report is to assess the outcome of assessments undertaken with clients.
When we start work with a client a start assessment is completed that generates a score. during our work with the client further assessments will be undertaken. these are either review assessments or an exit assessment when we are coming to the end of the work.

What i need to do is find out across the service how many clients came out with a positive score, negative, no change or where the client is new and has an initial assessment only. for this exercise i am only using start and exit scores so have filtered out any review assessments.

This gives me two rows per client:

client id________assessment_date_________assessment_type__________score
14556___________18/02/2017______________start_assessment_________43
14556___________23/04/2017______________exit_assessment__________15
35421___________11/11/2017______________start_assessment_________34
35421___________18/01/2018______________exit_assessment__________43
59032___________16/08/2018______________start_assessment_________38
59032___________26/10/2018______________exit_assessment__________38
82122___________15/02/2019______________start_assessment_________21

I have grouped by client_id and in the group footer i have formulas that tell me if the score is positive, negative, no change or only initial assesment

What I'd like to do is summarise all the positives, negatives etc,

I have the following formulas,

Score_summary
if (isnull({#count_assessments}) or {#count_assessments} =1) then
"Initial Assessment" else

if previous ({@score}) > {@score} then "Positive" else
if previous ({@score}) < {@score} then "Negative" else
if previous ({@score}) = {@score} then "No Change"

This formula is in the group footer


positive formula
if InStr(( {@compare} ), 'Positive' ) > 0 then 1
the formula's for the other types is the same
This formula is in the group footer.

but when i come to sum the counts of positives, negatives etc in the report footer i am presented with an error "This field cannot be summarised"

RE: Comparing scores and summarising into a table.

That is probably because you are using PREVIOUS in the formula. Now you should create a manual running total. So I think you could have one formula to do the totals. Something like this in the group footer.

Shared numbervar Positive;
Shared numbervar Negative;
Shared numbervar NoChange;

if {@compare} = 'Positive' then Positive := Positive + 1;
else if {@compare} = 'Negative' then Negative := Negative + 1;
else NoChange := NoChange +1;

Then have three formulas to just display the totals. i.e. the positive formula would like this: Shared Positive;

I am assuming that you would want the display formulas in the report footer.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close