Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear all
I have problem to get the correct Grouping using Class in following orders:
Subject | Grouping | 2012 | 2013 | 2014 |
English | 61-70 | 2 | 1 | 1 |
English | 71-80 | 1 | 3 | |
English | 81-90 | 1 | 2 | |
English | 91-100 | 1 |
Thank you
Tracy
Attaching doc here.
Sorry, attached the wrong file. please use Test-2.qvw attached below
Don't have access to qvw as having PE edition but your main issue is getting the start from 61 or something else - see if below output works for you - '60 - 70' means 60 <=marks <70, so in reality it counts between 60-69, 70 is counted in 70-80.
Attaching doc here.
Dear Digvijay
Thanks for your quick response.
Instead of specify the condition in expression, can you advise how to write a script ?
Following script was presented in the attached file but not working, please help.
CrossTable(Year, Data, 4)
LOAD
Dual(SubField(Class(Subject,10,'',1),' <= < ',1)&' - '&(SubField(Class(Subject,10,'',1),' <= < ',2)-1), Class(Subject,10,'',1)) as [Grouping],
* FROM
[Exam Results.xlsx]
(ooxml, embedded labels, table is [Exam Results]);
Thank you
Tracy
See attached -
Table:
CrossTable(Year, Marks, 3)
LOAD
Seq,
Name,
Subject,
[2012],
[2013],
[2014]
FROM
[Exam Results.xlsx]
(ooxml, embedded labels, table is [Exam Results]);
Final:
Load *,Replace(Class(Marks,10),'<= x <','-') as Grouping Resident Table;
Drop table Table;