Skip to Content

Field symbol has not yet been assigned -ABAP error in APO DP

Hello experts,

While loading selection in planning book, we are facing an error "Field symbol has not yet been assigned" the code is as follows .

data:

    l_act_line type /SAPAPO/MXROW,

    l_s_tab    type /SAPAPO/MXSOP.



  field-symbols:

    <l_s_line_index> like line of line_index.





*&---------------------------------------------------------------------*

*& (1) Initialization

*&---------------------------------------------------------------------*



*#TR# (1a) Initialize Return values

  clear f_argument.



*#TR# (1b) Get first parameter (ACT_LINE)

  _advf_value_tab_get_value value_tab[] l_act_line f_calc_error.

  if f_calc_error = true. break-point id /SAPAPO/ADV__EXECUTION. exit. endif.







*&---------------------------------------------------------------------*

*& (2) Read cell from C_T_TAB (res. C_TH_TAB

*&---------------------------------------------------------------------*



*#TR# (2a) Note 1008841: This macro function makes only sense for key figures distinguishing between 0 and nothing. For

*#TR# a key figure that does not distinguish between 0 and nothing, this macro function returns always 0 (false)

  read table line_index with key line = l_act_line binary search assigning <l_s_line_index>.

  assert id /SAPAPO/ADV__EXECUTION condition sy-subrc = 0.



  if <l_s_line_index>-calc_init_flags = abap_false.

    f_argument = gs_c_advf_f_argument-false.

    return.

  endif.

SPAN {
font-family: "Courier New";
font-size: 10pt;
color: #000000;
background: #FFFFFF;
}
.L0S31 {
font-style: italic;
color: #808080;
}
.L0S32 {
color: #3399FF;
}
.L0S52 {
color: #0000FF;
}
.L0S55 {
color: #800080;
}
.L0S70 {
color: #808080;
}

#TR# (2b) Read corresponding cell from C_T_TAB (res. C_TH_TAB)

*#TR# If an entry is found, the cell is not initial (return value = 0)

*#TR# Note 1008841: There are two criteria for a cell to be initial:

*#TR#   - no entry is contained in table C_T_TAB (res. C_TH_TAB)

*#TR#   - entry is contained, but has change mode GS_C_TS_KEYF_CHANGE_MODE-INITIAL_SET

  if c_t_tab is supplied.

    read table c_t_tab with table key z = l_act_line c = act_column into l_s_tab.

    if sy-subrc <> 0 or l_s_tab-change_mode = gs_c_ts_keyf_change_mode-initial_set.

      f_argument = gs_c_advf_f_argument-true.

    else.

      f_argument = gs_c_advf_f_argument-false.

    endif.

  elseif c_th_tab is supplied.

    read table c_th_tab with table key z = l_act_line c = act_column into l_s_tab.

    if sy-subrc <> 0 or l_s_tab-change_mode = gs_c_ts_keyf_change_mode-initial_set.

      f_argument = gs_c_advf_f_argument-true.

    else.

      f_argument = gs_c_advf_f_argument-false.

    endif.

  else.

    break-point id /SAPAPO/ADV__EXECUTION.

  endif.





endfunction.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Feb 17, 2017 at 12:22 PM

    Hi Vishal,

    It looks issue comes up from some macro definition.

    Can you please check if you see issue after loading data in a view which does not have macros? This way we can pin point which macro is creating the problem and then troubleshoot it.

    Thanks & Best Regards,

    Sonali

    Add comment
    10|10000 characters needed characters exceeded