пятница, 29 августа 2014 г.

Удаляем записи в таблице. BW 7.3

In se16 when records displayed
select the record to delete then enter into debug mode with /h then in debugging screen
create breakpoint in the subroutine "SET_STATUS_VAL"
in program "SAPLSETB". Now press f8.
Now modify the "code" variables value to DELE and click pencil icon.

now delete button appears and it worked for me.


Взято с форума.

среда, 27 августа 2014 г.

ITAB_DUPLICATE_KEY

Что произошло?

    Error in the ABAP Application Program

    The current ABAP program "SAPLRSAODS" had to be terminated because it has
    come across a statement that unfortunately cannot be executed.


Помогло что-то из этого, SE38:

ANALYZE_RSZ_TABLES,
RSAR_PSA_DUPL_REC_CHECK,
RDDPUTR_FIND_DUPLICATE_KEYS,
RS_FIND_ISOSMAP_DUPREC,
RSAR_RSTSODS_DUPLICATES,
RSAR_TRANSTRUCTURE_CHECK.


http://scn.sap.com/thread/285461
http://scn.sap.com/thread/265661


После копирования системы возникают ошибки с переносами и (как у меня с запуском цепочки). Один из способов лечения – проверить системную таблицу RSISOSMAP, ниже привожу выдержку из текста сап ноты (сама нота в pdf прилагается).
Reproducing the Issue
  1. Trigger the problematic DTP via transaction code RSA1
  2. Use the monitor function to view the DTP details/log
  3. Transaction code ST22 will contain the relevant ITAB_DUPLICATE_KEY dump.
Cause
This ABAP dump indicates that there may be duplicate transfer structure entries in the table RSISOSMAP.
This type of inconsistency normally happens only after system copies.
Resolution
In transaction code SE38, execute program RS_FIND_ISOSMAP_DUPREC to identify if there are any duplicate transfer structure names in table RSISOSMAP.
If there are duplicates, you can delete these by executing program RSAR_RSISOSMAP_REPAIR in Repair mode via SE38. 

среда, 20 августа 2014 г.

Просмотр активной цепочки (ну или любого журнала любой цепочки)

Программа:
RSPC_MAINTAIN_SINGLE    -   Ведение цепочек процесов (1 цепочка)

Делаем из неё FM и если в Z-интерфейсе запускаем цепочку через RSPC_CHAIN_START, то делаем кнопку, чтобы сразу в лог провалиться.



На всякий случай код:

*&---------------------------------------------------------------------*
*& Report  RSPC_MAINTAIN                                               *
*&                                                                     *
*&---------------------------------------------------------------------*
*&                                                                     *
*&                                                                     *
*&---------------------------------------------------------------------*

report  rspc_maintain_single                           .

parameterschain   type rspc_chain,
            logid   type rspc_logid,
            display type rs_bool as checkbox default 'X'.

datal_bwclient type symandt.
call function 'RSCC_RSADM_ACC'
  exporting
    fieldname  'BWMANDT'
    action     'S'
  changing
    adminvalue l_bwclient
  exceptions
    others     1.
if sy-subrc <> or l_bwclient <> sy-mandt.
* ==== no BW or non BW client: call old TA ====
  datal_t_chaint type rspc_t_chaint,
        l_mode     type rspc_frontendmode.

  if not logid is initial.
    l_mode 'LOG'.
  else.
    l_mode 'PLAN'.
  endif.
  call function 'RSPC_CHAIN_MAINTAIN'
    exporting
      i_chain         chain
      i_mode          l_mode
      i_logid         logid
      i_display_only  display
    importing
      e_t_chaint      l_t_chaint
    exceptions
      internal_error  1
      aborted_by_user 2
      others          3.
  if sy-subrc <> 0.
    message id sy-msgid type 'S' number sy-msgno
            with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
            display like 'E'.
  endif.
  export chaint from l_t_chaint to memory id 'CHAIN'.
else.
* ==== BW client: Call DWB ====
  datal_r_request type ref to cl_rsawbn_request,
        l_objnm     type rsawbnobjnm,
        l_fcode     type syucomm.
  datal_r_state   type ref to cl_rspc_awb_navistack,
        l_s_navi    type rspc_s_navistack.

  l_objnm chain.
  if not logid is initial.
    l_fcode rsawc_c_tfc-display_log.
    l_s_navi-tree 'LOGS'.
    l_s_navi-mode 'LOG'.
  elseif display 'X'.
    l_fcode rsawc_c_tfc-display.
    clear l_s_navi-tree.
    l_s_navi-mode 'PLAN'.
  else.
    l_fcode rsawc_c_tfc-change.
    l_s_navi-tree 'RSPV'.
    l_s_navi-mode 'PLAN'.
  endif.
  create object l_r_request
    exporting
      i_awbobj rs_c_tlogo-process_chain
      i_objnm  l_objnm
      i_fcode  l_fcode.
  l_s_navi-view 'C'.
  l_s_navi-display_only display.
  create object l_r_state
    exporting
      i_s_navistack l_s_navi
      i_logid       logid.
  call method l_r_request->set_external_call_state
    exporting
      i_r_state l_r_state.
  cl_rsawbn_awb=>starti_r_request l_r_request ).
endif.