Variante 1 (kurz)
DATA: o_salv TYPE REF TO cl_salv_table.
...
LOOP AT o_salv->get_columns( )->get( ) ASSIGNING FIELD-SYMBOL(<c>).
<c>-r_column->set_short_text( |{ <c>-r_column->get_columnname( ) }| ).
<c>-r_column->set_medium_text( |{ <c>-r_column->get_columnname( ) }| ).
<c>-r_column->set_long_text( |{ <c>-r_column->get_columnname( ) }| ).
ENDLOOP.
Variante 2 (RTTS, RTTI)
DATA: o_alv TYPE REF TO cl_salv_table.
...
* Datendescriptor für Tabellenzeile (z.B.: Struct "ls_spfli") holen
DATA: o_struct TYPE REF TO cl_abap_structdescr.
o_struct ?= cl_abap_typedescr=>describe_by_data( ls_spfli ).
DATA: o_comp_tab TYPE abap_component_tab.
o_comp_tab = o_struct->get_components( ).
* Spalten der SALV-Table holen
DATA(lo_columns) = o_salv->get_columns( ).
DATA: lv_col TYPE REF TO cl_salv_column.
LOOP AT o_comp_tab INTO DATA(ls_comp).
lv_col ?= lo_columns->get_column( |{ ls_comp-name }| ).
* Spaltennamen auf Structnamen ändern
lv_col->set_short_text( | { ls_comp-name } | ).
lv_col->set_medium_text( | { ls_comp-name } | ).
lv_col->set_long_text( | { ls_comp-name } | ).
ENDLOOP.