SAP ABAP Data Element UPC_Y_FBVER (FM Combination Check)
Hierarchy
SAP_BW (Software Component) SAP Business Warehouse
   BW-PLA-BPS (Application Component) Business Planning and Simulation
     UPC (Package) SEM-BPS: General Functions
Basic Data
Data Element UPC_Y_FBVER
Short Description FM Combination Check  
Data Type
Category of Dictionary Type D   Domain
Type of Object Referenced     No Information
Domain / Name of Reference Type FUNCNAME    
Data Type CHAR   Character String 
Length 30    
Decimal Places 0    
Output Length 30    
Value Table TFDIR    
Further Characteristics
Search Help: Name    
Search Help: Parameters    
Parameter ID   
Default Component name    
Change document    
No Input History    
Basic direction is set to LTR    
No BIDI Filtering    
Field Label
  Length  Field Label  
Short 10 KM: C.Chck 
Medium 16 FM: Comb. Check 
Long 24 FM: Combination Check 
Heading 30 Function Combination Check 
Documentation

Definition

You can check whether valid characteristic combinationes were generated through data entry or planning functions with this function module.

The function module has the following parameters:

  1. I_AREA = the planning area (type UPC_Y_AREA)
  2. IS_CHAS = the characteristic combinations. Note that with multi-planning areas, the function module is called up with the multi-planning area belonging field string, although the Customizing is defined at the basic planning area. Therefore, you do program on a fixed structure, instead you communicate with the fields dynamically as in the example below. The field FISCPER is angesprochen in the example by the order ASSIGN COMPONENT '0FISCPER' OF STRUCTURE is_chas TO <fiscper>. This functions independently of the structure.
  3. ITO_CHA = the characteristics, which are to be checked (type UPC_YTO_CHA). The following special feature applies to compounded characteristics: The higher-level characteristics are also specified if this was not defined in the step.
  4. ITO_CHASEL = Selection condition on the characteristic combinations (type UPC_YTO_CHASEL).
  5. The exception is INVALID. If this exception is triggered, this must take place through the statement MESSAGE E... RAISING INVALID. The error message following MESSAGE is then passed on.

The following module checks whether the characteristics fiscal year ( = 0FISCYEAR ), posting period ( = 0FISCPER3 ) and 7 character period (= 0FISCPER) agree.


FUNCTION z_check_time_chas.
*"----------------------------------------------------------------------
*"*"Local interface:
*" IMPORTING
*" REFERENCE(I_AREA) TYPE UPC_Y_AREA
*" REFERENCE(IS_CHAS) TYPE ANY
*" REFERENCE(ITO_CHA) TYPE UPC_YTO_CHA
*" REFERENCE(ITO_CHASEL) TYPE UPC_YTO_CHASEL
*" EXCEPTIONS
*" INVALID
*"----------------------------------------------------------------------
DATA: l_fiscper(7) TYPE n.

FIELD-SYMBOLS: <fiscper>, <fiscyear>, <fiscper3>.

ASSIGN COMPONENT '0FISCPER' OF STRUCTURE is_chas TO <fiscper>.
ASSIGN COMPONENT '0FISCYEAR' OF STRUCTURE is_chas TO <fiscyear>.
ASSIGN COMPONENT '0FISCPER3' OF STRUCTURE is_chas TO <fiscper3>.

l_fiscper(4) = <fiscyear>.
l_fiscper+4(3) = <fiscper3>.

IF l_fiscper <> <fiscper>.
* Combination of fiscal year/ period &1 and 7 character period &2 falsch
MESSAGE e001(Z00) WITH l_fiscper <fiscper>
RAISING invalid.
ENDIF.
ENDFUNCTION.

History
Last changed by/on SAP  20130604 
SAP Release Created in 31A