‎2007 Feb 07 3:42 PM
hi guys I have a table
username | last login | user locked | Activity group
DALEX | 01.01.2007 | X | XYZ1
DALEX | 01.01.2007 | X | XYZ2
SHERB | 01.01.2007 | X | XYZ1
SHERB | 01.01.2007 | X | XYZ2
and i want to have it to be outputted into groups like this
DALEX | 01.01.2007 | X | XYZ1
*empty|empty|empty*| XYZ2
SHERB | 01.01.2007 | X | XYZ3
*empty|empty|empty*| XYZ4
I have tried sorting across multiple fields but it hides the 01.01.2007 for SHERB as it is the same data as DALEX.
Does anyone know of a way to only output data in an ALV grid that is different from the first row for each username?
‎2007 Feb 07 3:45 PM
have you given like this
it_sort-fieldname = 'USERNAME'.
it_sort-spos = '1'.
it_sort-up = 'X'.
append it_sort.
‎2007 Feb 07 3:50 PM
Thanks but this is is not what I want.
If I do this it will group the usernames, but not remove the duplicate dates or anything else.
If I sort the dates aswell, all of the dates will be grouped and you will not be able to see the dates for different usernames
‎2007 Feb 07 4:02 PM
hi,
You can try in this way, but the report can not be sorted after we get the ALV output.
Populate the final internal table with spaces..
loop at <itab>.
abc | def | pqr |10
| | | 20
at new <f1>.
populate 4 fields
endat.
// clear first 3 fields
append final.
endloop.
Regards,
Sailaja.