2010 Jul 20 5:14 PM
Hi all
Wanted to ask how to or is it possible to include if-statement or case in a ABAP Open SQL
example
SELECT IF(NAME = '' , 'UNKNOWN', NAME ) FROM TABLE1 order by NAME ASCENDING.
Because I am trying to sort the data and the null value should be the last record to be seen.
Hi
It is not possible to include if-statement or case in Abap open sql.
Inorder to get the null value as last record sort the table with key as field which as null values.
Thanks!!
2010 Jul 20 6:26 PM
Hi
It is not possible to include if-statement or case in Abap open sql.
Inorder to get the null value as last record sort the table with key as field which as null values.
Thanks!!
2010 Jul 20 9:31 PM
More proper way to do this in ABAP is IMHO to use SELECT ... WHERE into an internal table and then sort the table (SORT).
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |