FI related function module or logic required
hi all,
need to calculate ending balance for the data present in internal table .
loop .
end balance = all dmbtrs in s(debit) - all dmbtrs - h (credit).
at new month.
end = end balance for every month .
endloop.
the pblm is i want monthly wise data . if it s in between 1 yr its fine but if the table has data for two r three years at tht time the above logic will not work . plz help.
regards,
vishnu.
Hi Vishnu,
Just a simple workaround can be split the data into different internal table by the fiscal year. You can write a logic based on that.
Regards,
Atish
Similar Messages
-
Hi Experts,
The following is the ABAP Code used in Function Module to extract Master Data from R/3 to BW.Could please convert that into human language (Explain logic of code)
FUNCTION MDEX_MATERIAL_MD .
""Lokale Schnittstelle:
*" IMPORTING
*" VALUE(I_REQUNR) TYPE SBIWA_S_INTERFACE-REQUNR OPTIONAL
*" VALUE(I_CHABASNM) TYPE SBIWA_S_INTERFACE-CHABASNM OPTIONAL
*" VALUE(I_MAXSIZE) TYPE SBIWA_S_INTERFACE-MAXSIZE OPTIONAL
*" VALUE(I_INITFLAG) TYPE SBIWA_S_INTERFACE-INITFLAG OPTIONAL
*" VALUE(I_UPDMODE) TYPE SBIWA_S_INTERFACE-UPDMODE OPTIONAL
*" VALUE(I_DATAPAKID) TYPE SBIWA_S_INTERFACE-DATAPAKID OPTIONAL
*" VALUE(I_S_TIMEINT) TYPE SBIWA_S_TIMEINT OPTIONAL
*" VALUE(I_RLOGSYS) TYPE SRSC_S_INTERFACE-RLOGSYS OPTIONAL
*" VALUE(I_PRIVATE_MODE) OPTIONAL
*" TABLES
*" I_T_SELECT TYPE SBIWA_T_SELECT OPTIONAL
*" I_T_FIELDS TYPE SBIWA_T_FIELDS OPTIONAL
*" E_T_BIW_MARA_S STRUCTURE BIW_MARA_S OPTIONAL
*" E_T_BIW_MARC_S STRUCTURE BIW_MARC_S OPTIONAL
*" E_T_BIW_MARD_S STRUCTURE BIW_MARD_S OPTIONAL
*" E_T_BIW_MVKE_S STRUCTURE BIW_MVKE_S OPTIONAL
*" E_T_BIW_MARM_S STRUCTURE BIW_MARM_S OPTIONAL
*" EXCEPTIONS
*" NO_MORE_DATA
*" ERROR_PASSED_TO_MESS_HANDLER
function acts as a S-API-compatible interface for the SD-extractor
MATERIAL_DYNAM_DATA_SELECTION
STATICS: L_FIRST_CALL TYPE SBIWA_FLAG,
L_NO_SELECT TYPE C.
DATA: L_SUBRC TYPE SBIWM_SUBRC.
DATA: L_T_CHABASCMP LIKE RSSOSFIELD OCCURS 0 WITH HEADER LINE,
L_S_REQUEST TYPE RSAP_S_REQUEST,
L_SLOGSYS LIKE TBDLS-LOGSYS,
L_RODCHABGEN LIKE RODCHABGEN,
L_LINES TYPE I,
L_TX_SELECT TYPE SBIWA_TX_SELECT,
L_T_SELECT TYPE SBIWA_T_SELECT,
L_S_SELECT TYPE SBIWA_S_SELECT.
DATA: L_T_MARA LIKE MARA OCCURS 10 WITH HEADER LINE,
L_T_MARC LIKE MARC OCCURS 10 WITH HEADER LINE,
L_T_MARD LIKE MARD OCCURS 10 WITH HEADER LINE,
L_T_MVKE LIKE MVKE OCCURS 10 WITH HEADER LINE,
L_T_MARM LIKE MARM OCCURS 10 WITH HEADER LINE.
DATA: L_S_MATNR_MATERIAL_KEYS LIKE PRE03,
L_S_WERKS_MATERIAL_KEYS LIKE PRE01,
L_S_LGORT_MATERIAL_KEYS LIKE PRE08,
L_S_VTLIN_MATERIAL_KEYS LIKE PRE10.
Variable to read compound information "note383430 insED08052001
DATA: i_chabasnm_cmp TYPE sbiwa_s_interface-chabasnm.
"note383430 insED08052001
IF I_INITFLAG = 'X'.
Initialization: check input parameters
buffer input parameters
prepare data selection
Invalid second initialization call -> error exit
IF NOT G_FLAG_INTERFACE_INITIALIZED IS INITIAL.
IF 1 = 2. MESSAGE E008(R3). ENDIF.
LOG_WRITE 'E' "message type
'R3' "message class
'008' "message number
' ' "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
ELSE.
G_FLAG_INTERFACE_INITIALIZED = SBIWA_C_FLAG_ON.
ENDIF.
Check for supported update mode
CASE I_UPDMODE.
WHEN SBIWA_C_UPDMODE_FULL.
WHEN SBIWA_C_UPDMODE_DELTAINIT.
WHEN SBIWA_C_UPDMODE_DELTA.
WHEN OTHERS.
IF 1 = 2. MESSAGE E011(R3). ENDIF.
LOG_WRITE 'E' "message type
'R3' "message class
'011' "message number
I_UPDMODE "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
ENDCASE.
Initialize variable to read compound information
i_chabasnm_cmp = i_chabasnm. "note383430 insED08052001
**Check InfoObject validity and set IO-dependent parameters
G_TAB1_FLG = G_TAB2_FLG = G_TAB3_FLG = G_TAB4_FLG = ' '.
g_tab5_flg = ' '. "note417314 insED04072001
G_NO_MARM = 'X'.
CASE I_CHABASNM.
WHEN '0MATERIAL'.
G_TAB1_FLG = 'X'.
G_TABLENAME = 'MARA'.
WHEN '0ARTICLE'. "note383430 insED30042001
G_TAB1_FLG = 'X'. "note383430 insED30042001
G_TABLENAME = 'MARA'. "note383430 insED30042001
i_chabasnm_cmp = '0MATERIAL'. "note383430 insED08052001
WHEN '0ME_MATERIAL'. "note759687
G_TAB1_FLG = 'X'. "note759687
G_TABLENAME = 'MARA'. "note759687
i_chabasnm_cmp = '0MATERIAL'. "note759687
WHEN '0MAT_PLANT'.
G_TAB2_FLG = 'X'.
G_TABLENAME = 'MARC'.
WHEN '0ART_PLANT'. "note383430 insED30042001
G_TAB2_FLG = 'X'. "note383430 insED30042001
G_TABLENAME = 'MARC'. "note383430 insED30042001
i_chabasnm_cmp = '0MAT_PLANT'. "note383430 insED08052001
WHEN '0MAT_ST_LOC'.
G_TAB3_FLG = 'X'.
G_TABLENAME = 'MARD'.
WHEN '0ART_ST_LOC'. "note383430 insED30042001
G_TAB3_FLG = 'X'. "note383430 insED30042001
G_TABLENAME = 'MARD'. "note383430 insED30042001
i_chabasnm_cmp = '0MAT_ST_LOC'. "note383430 insED08052001
WHEN '0MAT_SALES'.
G_TAB4_FLG = 'X'.
G_TABLENAME = 'MVKE'.
when '0ART_SALES'. "note383430 insED30042001 "delED
g_tab4_flg = 'x'. "note383430 insED30042001 "delED
g_tablename = 'MVKE'. "note383430 insED30042001 "delED
WHEN '0ART_SALES'. "insED
G_TAB4_FLG = 'X'. "insED
G_TABLENAME = 'MVKE'. "insED
i_chabasnm_cmp = '0MAT_SALES'. "note383430 insED08052001
WHEN '0MAT_UNIT'.
G_TAB1_FLG = 'X'. "note417314 delED04072001
g_tab5_flg = 'X'. "note417314 insED04072001
G_TABLENAME = 'MARM'.
G_NO_MARM = ' '.
WHEN OTHERS.
IF 1 = 2. MESSAGE E009(R3). ENDIF.
LOG_WRITE 'E' "message type
'R3' "message class
'009' "message number
I_CHABASNM "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
ENDCASE.
** fill parameter buffer for data extraction calls
G_S_EXTR_IF-REQUNR = I_REQUNR.
G_S_EXTR_IF-CHABASNM = I_CHABASNM.
G_S_EXTR_IF-MAXSIZE = I_MAXSIZE.
G_S_EXTR_IF-INITFLAG = I_INITFLAG.
G_S_EXTR_IF-UPDMODE = I_UPDMODE.
G_S_EXTR_IF-DATAPAKID = I_DATAPAKID.
g_s_interface-read_opt =.
G_S_INTERFACE-MAX_MATNR = I_MAXSIZE.
g_s_interface-max_lifnr =.
g_s_interface-max_kunnr =.
g_s_interface-max_werks =.
CASE I_UPDMODE.
WHEN SBIWA_C_UPDMODE_DELTA.
** settings for delta data transfer
** get additional information about current extraction
CALL FUNCTION 'RSAN_LOGSYS_DETERMINE'
EXPORTING
I_CLIENT = SY-MANDT
IMPORTING
E_LOGSYS = L_SLOGSYS.
L_S_REQUEST-SNDPRN = L_SLOGSYS.
L_S_REQUEST-RCVPRN = I_RLOGSYS.
*----- Fill Content release so get_rodchabgen will work ok -
PERFORM GET_BWBCRL IN PROGRAM SAPLRSAP "OSS 1054070/2000
USING L_S_REQUEST-RCVPRN "OSS 1054070/2000
CHANGING L_SUBRC. "OSS 1054070/2000
PERFORM GET_RODCHABGEN IN PROGRAM SAPLRSAP
USING L_RODCHABGEN
I_CHABASNM
L_S_REQUEST.
** get base characteristic information
PERFORM DETERMINE_COMPOSITES IN PROGRAM SAPLRSAM
TABLES L_T_CHABASCMP
USING I_CHABASNM.
USING i_chabasnm_cmp. "note383430 insED08052001
** Get information about modified data objects
PERFORM FILL_MD_SELECT_ENTRYTABLE IN PROGRAM SAPLRSAP
TABLES L_T_CHABASCMP
USING L_RODCHABGEN-MSGTYP
I_CHABASNM
CHANGING L_TX_SELECT
L_SUBRC.
DESCRIBE TABLE L_TX_SELECT LINES L_LINES.
IF L_LINES = 0.
L_NO_SELECT = 'X'.
ENDIF.
** fill key-table for extractor
REFRESH G_T_MATNR_MATERIAL_KEYS.
REFRESH G_T_WERKS_MATERIAL_KEYS.
REFRESH G_T_LGORT_MATERIAL_KEYS.
REFRESH G_T_VTLIN_MATERIAL_KEYS.
refresh g_t_marm_material_keys. "note417314 insED04072001
LOOP AT L_TX_SELECT INTO L_T_SELECT.
CASE I_CHABASNM.
WHEN '0MATERIAL' OR '0ARTICLE' "note383430 insED30042001
OR '0ME_MATERIAL'.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'MATNR'.
L_S_MATNR_MATERIAL_KEYS-MATNR = L_S_SELECT-LOW.
APPEND L_S_MATNR_MATERIAL_KEYS TO G_T_MATNR_MATERIAL_KEYS.
WHEN '0MAT_PLANT' OR '0ART_PLANT'. "note383430 insED30042001
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'MATNR'.
L_S_WERKS_MATERIAL_KEYS-MATNR = L_S_SELECT-LOW.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'WERKS'.
L_S_WERKS_MATERIAL_KEYS-WERKS = L_S_SELECT-LOW.
APPEND L_S_WERKS_MATERIAL_KEYS TO G_T_WERKS_MATERIAL_KEYS.
WHEN '0MAT_ST_LOC' OR '0ART_ST_LOC'.
"note383430 insED30042001
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'MATNR'.
L_S_LGORT_MATERIAL_KEYS-MATNR = L_S_SELECT-LOW.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'WERKS'.
L_S_LGORT_MATERIAL_KEYS-WERKS = L_S_SELECT-LOW.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'LGORT'.
L_S_LGORT_MATERIAL_KEYS-LGORT = L_S_SELECT-LOW.
APPEND L_S_LGORT_MATERIAL_KEYS TO G_T_LGORT_MATERIAL_KEYS.
WHEN '0MAT_SALES' OR '0ART_SALES'. "note383430 insED30042001
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'MATNR'.
L_S_VTLIN_MATERIAL_KEYS-MATNR = L_S_SELECT-LOW.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'VKORG'.
L_S_VTLIN_MATERIAL_KEYS-VKORG = L_S_SELECT-LOW.
READ TABLE L_T_SELECT
INTO L_S_SELECT
WITH KEY FIELDNM = 'VTWEG'.
L_S_VTLIN_MATERIAL_KEYS-VTWEG = L_S_SELECT-LOW.
APPEND L_S_VTLIN_MATERIAL_KEYS TO G_T_VTLIN_MATERIAL_KEYS.
ENDCASE.
ENDLOOP.
IF L_SUBRC <> 0.
IF 1 = 2. MESSAGE E009(R3). ENDIF.
LOG_WRITE 'E' "message type
'R3' "message class
'009' "message number
I_CHABASNM "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
EXIT.
ENDIF.
** settings for full data transfer or delta init.
*----- Selektionsbedingungen müssen immer übernommen werden -
WHEN sbiwa_c_updmode_full "DEL"TH090800
OR sbiwa_c_updmode_deltainit. "DEL"TH090800
REFRESH g_t_sel_table. "DEL"TH090800
LOOP AT i_t_select INTO l_s_select. "DEL"TH090800
g_s_sel_table-table = g_tablename. "DEL"TH090800
g_s_sel_table-field = l_s_select-fieldnm. "DEL"TH090800
MOVE-CORRESPONDING l_s_select TO g_s_sel_table. "DEL"TH090800
APPEND g_s_sel_table TO g_t_sel_table. "DEL"TH090800
ENDLOOP. "DEL"TH090800
WHEN OTHERS.
ENDCASE.
*----- Selektionsbedingungen müssen immer übernommen werden -
REFRESH G_T_SEL_TABLE. "INS"TH090800
LOOP AT I_T_SELECT INTO L_S_SELECT. "INS"TH090800
G_S_SEL_TABLE-TABLE = G_TABLENAME. "INS"TH090800
G_S_SEL_TABLE-FIELD = L_S_SELECT-FIELDNM. "INS"TH090800
MOVE-CORRESPONDING L_S_SELECT TO G_S_SEL_TABLE. "INS"TH090800
APPEND G_S_SEL_TABLE TO G_T_SEL_TABLE. "INS"TH090800
ENDLOOP. "INS"TH090800
REFRESH G_T_FIELDS.
APPEND LINES OF I_T_FIELDS TO G_T_FIELDS.
ELSE. "Initialization mode or data extraction ?
IF ( G_MORE_DATA_EXISTS = ' ' ) AND ( G_COUNTER_DATAPAKID NE 0 ).
RAISE NO_MORE_DATA.
EXIT.
ENDIF.
IF G_S_EXTR_IF-UPDMODE = SBIWA_C_UPDMODE_DELTA.
IF NOT L_NO_SELECT IS INITIAL.
RAISE NO_MORE_DATA.
ENDIF.
ENDIF.
IF ( G_MORE_DATA_EXISTS = 'X' ) OR ( G_COUNTER_DATAPAKID = 0 ).
REFRESH L_T_MARA.
REFRESH L_T_MARC.
REFRESH L_T_MARD.
REFRESH L_T_MVKE.
REFRESH L_T_MARM.
CALL FUNCTION 'MATERIAL_DYNAM_DATA_SELECTION'
EXPORTING
NO_MARM_DATA = G_NO_MARM
READ_MARA_DATA = G_TAB1_FLG
READ_MARC_DATA = G_TAB2_FLG
READ_MARD_DATA = G_TAB3_FLG
READ_MVKE_DATA = G_TAB4_FLG
read_marm_data = g_tab5_flg "note417314 insED04072001
JOIN_OPTION = 'O'
IN_MAX_MATNR = G_S_INTERFACE-MAX_MATNR
TABLES
IN_SELECT_FIELDS = G_T_SEL_TABLE
IN_MATNR_KEYS = G_T_MATNR_MATERIAL_KEYS
IN_WERKS_KEYS = G_T_WERKS_MATERIAL_KEYS
IN_VTLIN_KEYS = G_T_VTLIN_MATERIAL_KEYS
IN_LGORT_KEYS = G_T_LGORT_MATERIAL_KEYS "insED22032001
in_marm_keys = g_t_marm_material_keys "note417314
"insED04072001
OUT_MARA_TAB = L_T_MARA
OUT_MARC_TAB = L_T_MARC
OUT_MARD_TAB = L_T_MARD
OUT_MVKE_TAB = L_T_MVKE
OUT_MARM_TAB = L_T_MARM
CHANGING
MORE_DATA_EXISTS = G_MORE_DATA_EXISTS
EXCEPTIONS
WRONG_INPUT_DATA = 1
OTHERS = 2
IF SY-SUBRC <> 0.
IF 1 = 2. MESSAGE E011(R3). ENDIF.
LOG_WRITE 'E' "message type
'R3' "message class
'011' "message number
SY-SUBRC "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
ENDIF.
G_COUNTER_DATAPAKID = G_COUNTER_DATAPAKID + 1.
LOOP AT L_T_MARA.
MOVE-CORRESPONDING L_T_MARA TO E_T_BIW_MARA_S.
APPEND E_T_BIW_MARA_S.
ENDLOOP.
LOOP AT L_T_MARC.
MOVE-CORRESPONDING L_T_MARC TO E_T_BIW_MARC_S.
provide additional attributes not contained in MARC
PERFORM MARC_ADD_ATTRIBUTES CHANGING E_T_BIW_MARC_S
L_SUBRC.
IF L_SUBRC <> 0.
IF 1 = 2. MESSAGE E501(R§). ENDIF.
"insED03082001 begin note216922
log_write 'W' "message type
'R§' "message class
'501' "message number
e_t_biw_marc_s-werks "message variable 1
' '. "message variable 2
"insED03082001 end note216922
"delED03082001 begin note216922
LOG_WRITE 'E' "message type
'R§' "message class
'501' "message number
E_T_BIW_MARC_S-WERKS "message variable 1
' '. "message variable 2
RAISE ERROR_PASSED_TO_MESS_HANDLER.
"delED03082001 end note2169222
ENDIF.
APPEND E_T_BIW_MARC_S.
ENDLOOP.
LOOP AT L_T_MARD.
MOVE-CORRESPONDING L_T_MARD TO E_T_BIW_MARD_S.
APPEND E_T_BIW_MARD_S.
ENDLOOP.
LOOP AT L_T_MVKE.
MOVE-CORRESPONDING L_T_MVKE TO E_T_BIW_MVKE_S.
APPEND E_T_BIW_MVKE_S.
ENDLOOP.
LOOP AT L_T_MARM.
MOVE-CORRESPONDING L_T_MARM TO E_T_BIW_MARM_S.
APPEND E_T_BIW_MARM_S.
ENDLOOP.
ENDIF.
ENDIF.
ENDFUNCTION.
ThanksHi,
This might not be the right forum for this. You can post your question in more relevant forum like Netweaver-Exchange Infrastructure. -
Function module for logical file path and name
Hello all,
I am wondering is there any function module available to translate a logical file path to a physical file path and a logical file name to a physical file name? Thanks a lot!
Regards,
AnyiPlease check the FM FILE_NAME_GET.
CALL FUNCTION <b>'FILE_GET_NAME'</b>
EXPORTING
logical_filename = 'ZDELCHKREP'
parameter_1 = it_cntry-cntry
IMPORTING
file_name = l_file
EXCEPTIONS
file_not_found = 08.
CALL FUNCTION <b>'FILE_GET_NAME_USING_PATH'</b> EXPORTING
logical_path = 'ZDELCHKREP'
file_name = l_file
IMPORTING
file_name_with_path = l_file.
Message was edited by: Anurag Bankley
Message was edited by: Anurag Bankley -
Function module to calculate Requirements !!!! Pls Advice
Hello friends ,
I need to find the function module used to calculate the Capacity Requirements (Hours) in CM01 transaction . Is there any function module using which this SAP program calculates the Requirements( Hours) . Please advice .
Thank youHi Hari,
Try the FM "CBP_EXC_WC_CAPACITY_REQUEST".
Hope it helps.
regards,
Raj -
Function module for logical database
hi
which function module will return the logical database for a given application component from the SAP hierarchy.
Example:
Input- application component- LO
output- MSM, etc.,
Thank you.RS_COMPONENT_VIEW
TADIR and LDBT
LDB_INFO -
CATS related function modules needed
Hi,
I have requirement like i need to upload time details into sap from non sap.CATS is the Tcode for time details.
CAT2 to enter time. I want to enter time details.
If any function modules avilable for this it will be easy for my work. Through BDC we can able to do this.
But if function modules avilable for the same it will be very much helpful to me.
Regards
SandeepFunction group Function group short text
Function Module Name Short text for function module
CAPP
CATS_APPROVAL
CATS_APPROVAL0
CATS_DATABASE_GET_OBJEC
CATS_DISPLAY_LIST
CATS_DISPLAY_TREE_LIST
CATB
CATS_DISPLAY_ALV_LIST
CATS_DISPLAY_DOCUMENT
CATS_DISPLAY_OBJECT
CATS_DISPLAY_TARGET_DOCUMENTS
CATS_DISPLAY_TARGET_DOCUMENTS0
CATS_DISPLAY_TRANSFER_LIST
CATE
CATS_INITIALIZE_MESSAGE
CATF
CATS_CHECK_APPLICATION_CO
CATS_FILL_INTERFACE_CO
CATL
CATS_CHECK_ARBPL_VALID
CATS_DET_ARBID_BY_ARBPL
CATS_DET_ARBPL_BY_ARBID
CATS_DET_AUFNR_BY_AUFPL
CATS_DET_AUFNR_BY_AUFPL_TRANS
CATS_DET_AUFPL_BY_AUFNR
CATS_GET_KAPAR_FOR_KAPID
CATS_GET_LOGISTIC_TEXT
CATS_GET_TABLE_AUFNR
CATS_GET_TABLE_RCR01
CATL2
CATS_AC03
CATS_CHECK_AND_DIST_ACTIVITIES
CATS_CHECK_APPLICATION_LOGIST
CATS_CHECK_STATUS_ACTIVITY
CATS_CJ13
CATS_CONVERT_EXT_TO_INT
CATS_CONVERT_INT_TO_EXT
CATS_CY_LOAD_DISTRIBUTION
CATS_CY_LOAD_DISTRIBUTION_KORR
CATS_ENRICH_READ_DATA
CATS_FILL_INTERFACE_LO
CATS_FIND_TARGET_DOC_AFRU
CATP
CATS_CALL_TRANSACTION_CAT4
CATS_CHECK_ATT_ABS_AUTHORITY
CATS_CHECK_AUTHORITY
CATS_CHECK_AWART
CATS_CHECK_AWART_HOURS
CATS_CHECK_EMPLOYEE_ACTIVE
CATS_CHECK_PERNR_LIST
CATS_CHECK_PROFILE_AUTHORITY
CATS_CHECK_SINGLE_PERNR
CATS_COMPUTE_HOURS
CATS_DELETE_HR_INTERFACE
CATS_FILL_ICLVA
CATS_GET_ALP_CURRENCY
CATS_GET_BASIC_INFOTYPES
CATS_GET_EMPLOYEE_NAME
CATS_GET_INFOTYPE_0001
CATS_GET_INFOTYPE_0315
CATS_GET_PAY_SCALE_TYPE_AREA
CATS_GET_PERNR_LIST_0001
CATS_GET_TARGET_HOURS
CATS_HR_ABSENCE_ATTEND_TEXT
CATS_HR_ADD_WAGE_TYPE
CATS_HR_CHECK_001
CATS_HR_CHECK_ALP
CATS_HR_CHECK_INFOTYPE_BOOKED
CATS_HR_DETERMINE_INFTY
CATS_HR_DISPLAY_DOCUMENT
CATS_HR_GLOBAL_CHECK
CATS_HR_LGART_TEXT
CATS_HR_READ_POSITION_TEXT
CATS_HR_READ_PREMIUM_TEXT
CATPEXTERN
CATS_GET_ABSENCE_ATTENDANCE
CATS Cross-Application Time Sheet
CATS_BUILD_CATSD
CATS_CHECK_FACTORY_CALENDAR
CATS_CHECK_FACTORY_DATE
CATS_CHECK_INPUT
CATS_CHECK_PERNR
CATS_CONVERT_CATSDB_TO_CATSD
CATS_CONVERT_LONGTEXT
CATS_CREATE_NEW_RECORD
CATS_ENRICH_INPUT
CATS_EXTERNAL_INTERFACE
CATS_EXTERNAL_WORKLIST
CATS_FILL_INTERFACE_CPR
CATS_GET_COUNTER
CATS_GET_CUSTOMER_TEXT_FIELDS
CATS_GET_DERIVATIVES
CATS_GET_LONGTEXT
CATS_GET_UNIT_HOUR
CATS_GET_WORKLIST_TEXT_FIELDS
CATS_INTERFACE
CATSCHECK
CATS_EXTENDED_CHECK
CATS_GLOBAL_EXTENDED_CHECKS
CATSEXTERN Functions for External Linking
CATS_GET_INFLUENCES CATS: Read Field Selection
CATS_GET_PERIODSTART
CATSTOOLS
CATS_ACTIVATE_MESSAGES
CATS_CHECK_APPLICATION
CATS_CHECK_CATSDB_AFTER_SAVE
CATS_CHECK_CONSISTENCY_AT_SAVE
CATS_CO_SET_TRANSFER_FLAG
CATS_CO_UPDATE_CATSCOSUM
CATS_GET_PROFILE
CATS_GET_PROFILE_AUTHGROUP
CATS_GET_PROFILE_FROM_USER
CATS_GET_UPDATE_BUFFER
CATSXC
CATSXC_READ_CATS_PROFILE
CATSXC_READ_FEATURE_VALUES
CATSXC_ROUND_QUANTITY
CATSXC_UPDATE_COMP_DTL
CATSXC_UPDATE_TCATX_COMPONENTS
CATSXT
CATSXT_CHANGE_TIME_SHEET
CATSXT_DISPLAY_TIME_SHEET
CATSXT_EXTERNAL_INTERFACE
CATSXT_FIELD_SELECTION_MODIFY
CATSXT_GET_PERSONNEL_NUMBER
CATSXT_GET_TIME_SHEET_DATA
CATSXT_SET_CURRENT_WORKAREAS
CATSXT_START_GUI
CATSXT_TRAVEL_MANAGER_GET_DATA
CATSXT_TRAVEL_MANAGER_SET_DATA
CATSXT_ACCOBJ
CATSXT_ACCOBJ_SET_FIELDSELECT
CATSXT_ACCOBJ_SET_TIME_SHEET
CATSXT_ACCOBJ_SET_VALUES_TAB
CATSXT_CLEAR_ACCOUNTING_OBJECT
CATSXT_DETERMINE_OBJECT_NUMBER
CATSXT_GET_OBJECT_DATA
CATSXT_GET_OBJECT_NUMBER
CATSXT_GET_OBJTYPE_FOR_ACCOBJ
CATSXT_INIT_ACCOUNTING_OBJECT
CATSXT_SET_OBJECT_DATA
CATSXT_SET_OK_CODE_ACCOUNTING
CATSXT_APPR
CATSXT_APPR_SET_TOOLBAR
CATSXT_APPR_USER_COMMAND
CATSXT_EXIT_EXAMPLE
CATSXT_CUSTOMER_EXIT_EXAMPLE
CATSXT_F4
CATSXT_F4_OBART
CATSXT_F4_TASKLEVEL
CATSXT_F4_TASKTYPE
CATSXT_SET_F4_FOR_ACCOBJECT
CATSXT_SET_F4_FOR_TASKLEVEL
CATSXT_FUP
CATSXT_ENTRY_SHEET_DISPLAY
CATSXT_FUP_CATS_FLOW_INFO_GET
CATSXT_FUP_FLOW_BACK_INFO_GET
CATSXT_FUP_GET_HISTORY_FOR_CNT
CATSXT_FUP_RESET_HISTORY_BUFF
CATSXT_SERVICE_NUMBER_READ
CATSXT_UTIL
CATSXT_CALL_USER_DFLT_DIALOG
CATSXT_CHECK_DFLT_DERIV_ACTIVE
CATSXT_CHECK_TYPE_LEVEL_AUTH
CATSXT_CHECK_WORK_DAY
CATSXT_COMPARE_STRUCTURES
CATSXT_GET_ACCESS_KEY
CATSXT_GET_ADDRESS_DATA
CATSXT_GET_CENTRAL_CONTROL
CATSXT_GET_CUSTOMIZING
CATSXT_GET_DDIC_FIELDINFO
CATSXT_GET_HOLIDAYS
CATSXT_GET_SMARTFORM_NAME
CATSXT_GET_TEMPORARY_KEY
CATSXT_GET_USER_ID_OF_PERNR
CATSXT_LONGTEXT
CATSXT_MOVE_STRUC1_TO_STRUC2
CATSXT_OPTIMIZE_OUTPUT
CATSXT_OPTIMIZE_OUTPUT_TC
CATSXT_SIMPLE_TEXT_EDITOR
CATSXT_SPLIT_LONGTEXT
CATSXT_SUBSCREEN_CONTROL
CATSXT_TABSTRIP_CONTROL
CATSXT_USER_DFLT_DIALOG
CATSXT_WRITE_HEADER
CATS_CO
CATS_ACT_ALLOC_CHECK
CATS_ACT_ALLOC_SENDER_CHECK
CATS_CHECK_AC
CATS_COBL_CHECK
CATS_COST_ASSGMT_CHECK
CATS_ITS
CATS_ITS_GET_POPUP_STATUS
CATS_ITS_GET_SCREEN
CATS_ITS_MAKE_STRING_NUMERICAL
CATS_ITS_SET_OKCODE
CATS_ITS_FUNC_CO
CATS_GET_COSTCENTER_ACTIVITY
CATS_LEVELING
CATS_GET_LEVELING_DATA
CATS_SERVICES
CATS_GUID_GET_KEY
CTHR
CATS_ATTABS_COSTINSERT
CATS_BATCH_TRANSFER_HR
CATS_BATCH_TRANSFER_HR_BKG
CATS_BUILD_SEND_MAIL
CATS_CALL_RCATSTHR
CTXT
CATS_CO_READ_OBJECT_TEXT
CATS_HR_READ_OBJECT_TEXT
HRTIM00ABSATTEXT
CATS_ATTABS_CHECK
HRTIM00F4HELP
CATS_F4_HELP_AWART
CATS_F4_HELP_CURRENCY
CATS_F4_HELP_LGART
CATS_F4_HELP_PRAKN_PRAKZ
CATS_F4_HELP_TRFGR_TRFST
PTEX
CATS_CHECK_INFOTYPE_POSTED
revert back if u require Bapis. -
*****Function Module / Bapi name required*******
Hi,
Can anyone please tell the a Bapi (or) Function Module to add a contact person to Business Partner .
Regards,
Vijay
***Replies will definetely be rewarded****can u check this web log, may be it might be useful.
/people/gregor.wolf3/blog/2005/08/07/crm-setup-synchronisation-of-business-partners-into-groupware-private-contact-folders
regds,
kiran -
Function Module for RSAP001 requires Type Pool
Hi
I am not an ABAP Freak:
I want to set up a Function Module for RSAP0001.
Setting Import and / or Tables Parameters give an Activation error:
Type pool SBIWA has not been declared
Message no. FL031
Diagnosis:
You used a type from type pool & in the interface of a function module.
Procedure:
For the program to be syntactically correct, you must
declare the type pool in the global data declaration of the
function group using the 'TYPE-POOLS: &.' statement.
Where do I find the global data declaration of the
function group ?
Thank You
Best Wishes
MartinHi Martin,
When you click on the function group you will find many includes declared in it.
Some of them will be Include L<fgrp>UXX and there will be one include,
INCLUDE L<fgrp>TOP, this is the include in which you will have to make declarations, and here you will have to declare type pool.
Simply goto transaction SE38 and the the program name as L<functionfroupname>TOP and you can directly change this include.
Regards,
Durgesh. -
What are campaigns related function modules ?
Hi,
I want to find out open campaigns and marketing attributes based on partner function i.e., owner responsible and these open documents I need assign to another owner responsible. Which function module I need to read the details and which fm is to change owner responsible. Please guide me which fm i need to use how I can change to another employee responsible partner function.Hi divya,
Check out the package CRM_MKTPL which will give you all the function modules of Marketing. -
Function module or logic for Production order Classification Controlling
Hi All,
I am going to CO03 transaction and display Production Order . ThenI am following path: Header-->Classification Controlling. Now i can see the General Characterstic descritpton and Value.
Can some one give me the FM or logic, to read the Controlling Classification of Production Order.
Please provide me your valuable Logic.
Thanks in advance!Hi,
try this FM ' call function 'CLAF_CLASSIFICATION_OF_OBJECTS'
BAPI_PRODORDCONF_GETDETAIL
Prabhudas -
Need an E-mail related Function Module
Hi,
I need to send some kind of information or rather some notifications to the clients via e-mail. Thew information is in TEXT format. I have used FM"SO_OBJECT_SEND" but didnt helped me.
This E-mail function would be triggered if there's any kind of failure in the transaction and the same has to be notified to the clients.
Please suggest.
Thanks & Regards,This abap mail sending program demonstrate how you can send a mail to the user SAP Office mailbox.
REPORT ZSEND .
TABLES: KNA1.
data for send function
DATA DOC_DATA LIKE SODOCCHGI1.
DATA OBJECT_ID LIKE SOODK.
DATA OBJCONT LIKE SOLI OCCURS 10 WITH HEADER LINE.
DATA RECEIVER LIKE SOMLRECI1 OCCURS 1 WITH HEADER LINE.
SELECT * FROM KNA1 WHERE ANRED LIKE 'C%'.
WRITE:/ KNA1-KUNNR, KNA1-ANRED.
send data internal table
CONCATENATE KNA1-KUNNR KNA1-ANRED
INTO OBJCONT-LINE SEPARATED BY SPACE.
APPEND OBJCONT.
ENDSELECT.
insert receiver (sap name)
REFRESH RECEIVER.
CLEAR RECEIVER.
MOVE: SY-UNAME TO RECEIVER-RECEIVER,
'X' TO RECEIVER-EXPRESS,
'B' TO RECEIVER-REC_TYPE.
APPEND RECEIVER.
insert mail description
WRITE 'Sending a mail through abap'
TO DOC_DATA-OBJ_DESCR.
CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
EXPORTING
DOCUMENT_DATA = DOC_DATA
IMPORTING
NEW_OBJECT_ID = OBJECT_ID
TABLES
OBJECT_CONTENT = OBJCONT
RECEIVERS = RECEIVER
EXCEPTIONS
TOO_MANY_RECEIVERS = 1
DOCUMENT_NOT_SENT = 2
DOCUMENT_TYPE_NOT_EXIST = 3
OPERATION_NO_AUTHORIZATION = 4
PARAMETER_ERROR = 5
X_ERROR = 6
ENQUEUE_ERROR = 7
OTHERS = 8.
regards
vinod -
How to use Logical database in function module?
I will create a function module in HR.
but how to use Logical database in function module ? Logical database PNP always show screen.in function (RFC) code , it is a matter.You cannot attach the LDB to the main program of the function group.
- So you may [SUBMIT|https://www.sdn.sap.com/irj/sdn/advancedsearch?cat=sdn_all&query=submit&adv=false&sortby=cm_rnd_rankvalue] a report which use the LDB and get back the data (export/import), by default in the syntax of SUBMIT the selection-screen will not be displayed
- Use [LDB_PROCESS|https://www.sdn.sap.com/irj/sdn/advancedsearch?query=ldb_process&cat=sdn_all], fill a structured table for selection, and get data back in another table
- Use [HR function modules to read Infotypes|https://www.sdn.sap.com/irj/sdn/advancedsearch?cat=sdn_all&query=hrfunctionmodulestoread+Infotypes&adv=false&sortby=cm_rnd_rankvalue].
Regards -
Function Modules related to BOM
Hi BW Gurus,
I am having a requirement to extract data from the function module for the PP module for the standard BOM.
I found out some function modules for my requirement csap_mat_bom_read and my problem here when i am trying to create a generic data source on using this function module it displays a error msg " The specified table does not exist ".
I am working first on function modules please let me know whether these function modules useful to fetch data in BW or not.
Give me your input of how to proceed further.
Regards,
SyedHi Shahid
You cannot create a generic datasource directly on a SAP standard function module, you should either create a custom FM and use the standard FM to get the data to a internal table and pass the values to a structure of datasource. Or use SAP tables to extract data to ITAB.
Rahul -
Urgent: Problems in Generic Extraction by Function Module
Hi BW Gurus,
I am new to SDN and also new to generic extraction using function module. My requirement is to extract long text(142 char) from CRM to BW as the text is not stored in database table I used function module read_text with in another ZXXX function module copy of (RSAX_BIW_GET_DATA_SIMPLE). In my extract structure I used GUID(char,32), Langu, long text(142 char) and 2 placeholders. Text can be extracted by passing STXH table fields(Tdname, Tdid, Tdobject, Tdspars) to read_text as parameters and i also need to use CRMD_ORDERADM_H field GUID(32 char) to compare 1st 32 chars of tdname(70 char) with Guid to select Guids and loop thru this Guids and for each Guid i need to append lines of text to e_t_data but as i donot know ABAP i unable to write the code for this. Through my friends help i wrote code when i check in RSA3 it is displaying the text but when i replicate into BW and load into data target in monitor the status is red with records initially but afterwards it will be red status again with 0 from 0 records for initial load again.when i check on job logs the errors i have are:
The background job has created a job log file of 2Gb size and it is currently on a infinite loop writing entries into the SAP System Log that it cannot write to the Job log file due to Error 22 for write/read access to a file this is because of the datasource i have created. Please find my Function module and if anyone would please correct FM and send me that will be really great.I appreciate it in advance.
MY Function Module is:
FUNCTION Z_CRMORDERH_STR_TXT.
""Local Interface:
*" IMPORTING
*" VALUE(I_REQUNR) TYPE SRSC_S_IF_SIMPLE-REQUNR
*" VALUE(I_DSOURCE) TYPE SRSC_S_IF_SIMPLE-DSOURCE OPTIONAL
*" VALUE(I_MAXSIZE) TYPE SRSC_S_IF_SIMPLE-MAXSIZE OPTIONAL
*" VALUE(I_INITFLAG) TYPE SRSC_S_IF_SIMPLE-INITFLAG OPTIONAL
*" VALUE(I_READ_ONLY) TYPE SRSC_S_IF_SIMPLE-READONLY OPTIONAL
*" VALUE(I_REMOTE_CALL) TYPE SBIWA_FLAG DEFAULT SBIWA_C_FLAG_OFF
*" TABLES
*" I_T_SELECT TYPE SRSC_S_IF_SIMPLE-T_SELECT OPTIONAL
*" I_T_FIELDS TYPE SRSC_S_IF_SIMPLE-T_FIELDS OPTIONAL
*" E_T_DATA STRUCTURE YCRM_TEXT_STR OPTIONAL
*" EXCEPTIONS
*" NO_MORE_DATA
*" ERROR_PASSED_TO_MESS_HANDLER
***" EXCEPTIONS NO_MORE_DATA
*" ERROR_PASSED_TO_MESS_HANDLER
Tables: CRMD_ORDERADM_H, STXH.
Auxiliary Selection criteria structure
data: l_s_select type srsc_s_select.
Maximum number of lines for DB table
Statics: s_s_if type srsc_s_if_simple,
counter
s_counter_datapakid like sy-tabix,
Cursor
s_cursor type cursor.
data: i_crmtext type standard table of TLINE .
types: begin of xsreph ,
GUID type CRMD_ORDERADM_H-guid,
end of xsreph.
data: i_guid type standard table of xsreph.
data: I_TEXT type STXH-TDNAME.
data: xempl like YCRM_TEXT_STR occurs 0 with header line.
data: t_tab like dd03l-tabname.
Select ranges
ranges: l_r_guid for CRMD_ORDERADM_H-guid.
l_r_connid for sflight-connid.
Initialization mode (first call by SAPI) or data transfer mode
(following calls) ?
if i_initflag = sbiwa_c_flag_on.
Initialization: check input parameters
buffer input parameters
prepare data selection
Check DataSource validity
case i_dsource.
when 'yCRM_TEXT'. " for S_SREPH1
when others.
if 1 = 2. message e009(r3). endif.
this is a typical log call. Please write every error message like this
log_write 'E' "message type
'R3' "message class
'009' "message number
i_dsource "message variable 1
' '. "message variable 2
raise error_passed_to_mess_handler.
endcase.
append lines of i_t_select to s_s_if-t_select.
Fill parameter buffer for data extraction calls
s_s_if-requnr = i_requnr.
s_s_if-dsource = i_dsource.
s_s_if-maxsize = i_maxsize.
Fill field list table for an optimized select statement
(in case that there is no 1:1 relation between InfoSource fields
and database table fields this may be far from beeing trivial)
append lines of i_t_fields to s_s_if-t_fields.
we will do our selection based on what is in the p table for the
infoobject
else. "Initialization mode or data extraction ?
Data transfer: First Call OPEN CURSOR + FETCH
Following Calls FETCH only
First data package -> OPEN CURSOR
if s_counter_datapakid = 0.
Fill range tables BW will only pass down simple selection criteria
of the type SIGN = 'I' and OPTION = 'EQ' or OPTION = 'BT'.
LOOP AT S_S_IF-T_SELECT INTO L_S_SELECT WHERE FIELDNM = 'GUID'.
MOVE-CORRESPONDING L_S_SELECT TO L_R_GUID.
APPEND L_R_GUID.
ENDLOOP.
case i_dsource.
when 'YCRM_TEXT'. " for S_SREPH1
t_tab = 'CRMD_ORDERADM_H'.
endcase.
select GUID
from (t_tab)
into table i_guid where PROCESS_TYPE = 'ZACI' and ( OBJECT_ID < '0000000042').
select tdname from stxh into i_text where tdobject = 'TEXT'.
if sy-subrc ne 0.
message e009(r3).
this is a typical log call. Please write every error message like this
log_write 'E' "message type
'R3' "message class
'009' "message number
i_dsource "message variable 1
'No master data found'. "message variable 2
raise error_passed_to_mess_handler.
endif.
Determine number of database records to be read per FETCH statement
from input parameter I_MAXSIZE. If there is a one to one relation
between DataSource table lines and database entries, this is trivial.
In other cases, it may be impossible and some estimated value has to
be determined.
open cursor with hold s_cursor for
select (s_s_if-t_fields) from CRMD_ORDERADM_H
where GUID in L_R_GUID .
ENDIF.
Fetch records into interface table.
named E_T_'Name of extract structure'.
fetch next cursor s_cursor
appending corresponding fields
of table e_t_data
package size s_s_if-maxsize.
IF SY-SUBRC <> 0.
CLOSE CURSOR S_CURSOR.
RAISE NO_MORE_DATA.
ENDIF.
as we are doing this only once can use the select statement.
***data: crmtext like tline occurs 0 with header line.
**data: i_crmtext type standard table of TLINE.
**data: i_guid type standard table of xsreph.
data: l_guid type THEAD-TDNAME.
data: st_guid type xsreph.
data: st_crmtext type TLINE.
data: lan type THEAD-TDSPRAS.
lan = 'E'.
loop at i_guid into st_guid.
l_guid = st_guid-guid.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
ID = 'A002'
LANGUAGE = lan
NAME = l_guid
OBJECT = 'CRM_ORDERH'
ARCHIVE_HANDLE = 0
LOCAL_CAT = ' '
IMPORTING
HEADER =
TABLES
LINES = i_crmtext.
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8
e_t_data-guid = l_guid.
loop at i_crmtext into st_crmtext.
move lan to e_t_data-langu.
move st_crmtext-tdline to e_t_data-description.
append e_t_data.
endif.
endloop.
clear: st_guid,l_guid.
refresh: i_crmtext.
endloop.
S_COUNTER_DATAPAKID = S_COUNTER_DATAPAKID + 1.
endif.
ENDFUNCTION.
please Gurus as I donot know ABAP i appreciate if anyone would write a FM based on requirement and send me that will be really great this is my request. I gurantee of award points for good answers.
Regards
KishoreHi,
The statement <b>RAISE NO_MORE_DATA</b> should be active (uncommented) in your code. Otherwise, the infinte loop occurs.
See also, the Siggi's blog:
/people/siegfried.szameitat/blog/2005/09/29/generic-extraction-via-function-module
BTW, was it your thread here:
Re: Urgent: problems in extracting Long Text
Best regards,
Eugene -
Parallelization is not happening using asychnronous RFC in a function module
A BW data source ZTEST
has been created based on a function module ZTEST_FM to pull the
data into BW system from R/3.
(Have checked the parellel jobs running in SM66 transaction).
Inside the function module, an RFC function
module ZTEST_RFC1 has been called asynchronously to implement the parallelization
to improve the data extraction time into BW system.
Note: In this scenario asynchronous
RFC is used to implement the parallel processing.
The logic in the function module is as follows.
Function module ZTEST_FM Logic:
Fetch data from HRP1000 table into an internal table IT_HRP1000 for
OTYPE = ‘TN’.
Loop at IT_HRP1000 into work area (WA).
Call the RFC asynchronously by passing OBJID,OTYPE and ENDDA,
Calculate SOBID which is the required output field from the RFC
function module.
Populate the results into final internal table E_T_DATA.
The output structure contains the following fields.
OBJID
BEGDA
ENDDA
SOBID
Could you please give us some suggestions, to implement the parellel processing using asychronous RFC in this scenario.
Would appreciate your help.Your RFC call looks correct. For collecting the result you will need to code the callback routine Write_E_T_data. Inside the callback you can use the statement
RECEIVE RESULTS FROM FUNCTION ZFHLS_EX_TNM_ACADEMY_RFC1 IMPORTING <parameter list>
to retrieve the calculated result. For the declaration of the callback routine I recommend
FORM Write_E_T_data USING iv_name TYPE c.
The parameter iv_name containing the name of the RFC task turned out to be mandatory in my tests.
Maybe you are looking for
-
Why am I having the following problem with my MacBook?
It is actually pretty hard to explain but once in a while when I take my laptop out of sleep mode, following happens (by opening the screen and logging in).. and I am not quite sure why and wether or not there is a way to actually fix this? Thank you
-
help. iWeb won't update all the changes I make to my website. I've got a mobileMe account. it got some, but not all. "publish site changes" and "revert to saved" appear grayed out. never had trouble before. weird. Help?
-
Name Space Communication Error when Launching Workspace in Hyperion 11.1.2
Hi All, I've installed Hyperion 11.1.2. All the links were working fine after configuration. Now when i'm launching Workspace, it is giving the message as "Namespace communication Error". Why it is giving this message ? Why it didn't show this messag
-
SQL*Plus Install Problem (Ora-12705?- - -)
Hi, I bought a guide to sql featuring Oracle by phillip J.Pratt published by course Technology include Oracale8i Personal Edition realease 8.1.5 for Microsoft Window 98 and Oracle Developer 6.0. I follow the documentation to install. I think i got ri
-
when I open mymac book pro i click on safari and it goes straight to facebook. but for some reason now when i open safari i get a strange address and have to go to bookmarks to find facebook. anyone have a clue