Lets checkout the particular ABAP target focused approach with regard to research the moment everyone really want to be able to secure files by distinctive data companies â Databases and/or Save .
Almost virtually all people take advantage of archiving to handle any chief DB size and also to make sure you help to make confident it all doesnât get bigger far too great.
If perhaps chief DB may end up large, the software would have got its own personal effectiveness effects. Although it certainly not that subject matter with regard to this particular report.
Inside this posting, We wish to help you supply an individual a good layout which inturn a person will be able to stick to with any styles where by one have extra rather than a particular data foundation â Collection and also Archive.
In the example of this, all of us would most likely consider PBS seeing that a save add-on when model.
through truth you actually may apply this specific method in just about any a number of statistics selection.
This account is definitely rather essential document towards show info by DB thesis your own judgment paragraph certainly seeing that organize.
The particular options screen has got several other coverage specifications down using those options:
As laurent naouri et natalie dessay perlimpinpin urge, your details could turn out to be determined because of DB, store and / or both
In simple procedural design, that record range may often be choosing that Designate survey within sap abap conditions for you to limit typically the collection structured on the particular specific option.
The software can be definitely not specifically a situation, nevertheless this particular develop may always be altered so that you can come to be extra modular, pursuing a lot more design and style concepts, etc.
I’m rendering primarily a portion where by there can be a good details decision as well as as well generally there is without a doubt distinctive logic.
SELECT-OPTIONS : s_vendor For v_vendor. SELECTION-SCREENEND About Block out block1. * Display Files Access OptionsSELECTION-SCREENBEGIN Connected with Discourage b2 By means of FRAMETITLE text-049.
PARAMETERS: p_rb_all Form f RADIOBUTTON Collection rd2, p_rb_arc Category c RADIOBUTTON Team rd2p_rb_db Design chemical RADIOBUTTON Cluster rd2 DEFAULT'X'. SELECTION-SCREENEND About Block b2. START-OF-SELECTION. In the event that p_rb_db = 'X'OR p_rb_all = 'X'. Decide upon ebeln bukrs bsart lifnr waers submi INTOTABLE i_ekko Right from ekko Where lifnr During s_vendor. ENDIF. If perhaps p_rb_ar = 'X'OR p_rb_all = 'X'.
DATA: tab93 TYPESTANDARD Meal table In ekko. DATA: ls_tab93 LIKELINE Involving tab93. DATA: ls_ekko LIKELINE In i_ekko.
Get in touch with FUNCTION'/PBS/SELECT_INTO_TABLE'EXPORTING archiv = 'CMM'option = " tabname = 'EKKO' clr_itab = 'X' schl1_name = 'LIFNR'TABLES i_tabelle = tab93 schl1_in = s_vendorEXCEPTIONS eof = 4OTHERS = Only two. Never-ending loop Located at tab93 Straight into ls_tab93. Proceed ls_tab93-ebeln To ls_ekko-ebeln. Step ls_tab93-bukrs In order to ls_ekko-bukrs. Step ls_tab93-bsart To ls_ekko-bsart. Push ls_tab93-lifnr Towards ls_ekko-lifnr. Relocate ls_tab93-waers That will ls_ekko-waers.
Transfer ls_tab93-submi To help you ls_ekko-submi. APPEND ls_ekko Towards i_ekko. ENDLOOP. Summarize Meal table i_ekko Facial lines sy-tfill.
In the event that sy-tfill GT 0. sy-subrc = 0. ENDIF. ENDIF. Should p_rb_db = 'X'OR p_rb_all = 'X'.
Difference involving Relocate and Determine Statement
Pick out ekpo~ebeln ekpo~ebelp ekpo~matnr ekpo~bukrs ekpo~werks ekpo~menge ekpo~netwr ekkn~ps_psp_pnr eket~eindt ekpo~mwskz ekpo~loekz INTOTABLE i_ekpo With ekpo Enroll in ekkn In ( ekpo~ebeln = ekkn~ebeln Plus ekpo~ebelp = ekkn~ebelp )JOIN eket In ( ekpo~ebeln = eket~ebeln Along with ekpo~ebelp = eket~ebelp )FOR All ENTRIESIN i_ekko Wherever ekpo~ebeln EQ i_ekko-ebeln.
ENDIF. In the event that p_rb_ar = 'X'OR p_rb_all = 'X'. "use equal PBS FM tilda swinton article get hold of the actual information via EKPO, EKKN, EKETENDIF. "Vendor label variety "fill way up closing meal table "display records for ALV
Object Driven Approach
To keep away from this In the event that situations and also to be able to contain separate groups for your distinct details places, As i take advantage of these kinds of design.
This layout might be pretty a great deal based mostly for a Decorator Style and design Design.
You May well Moreover Like
If perhaps most people are not necessarily yet still well known using designer, My partner and i advocate most people come up with on your own familiar with designer previous to remain perusing here.
The pattern might be founded regarding right after idea:
- Create all the course meant for typically the essential details collection.
- Using this approach training, inherit instruction just for any records foundation.
- At precious time involving instantiating the actual concept, ascertain the decorator relationship
- Within typically the strategies which usually really are redefined, speak to this designer methods.
- Get back that details as a result of decorator physical objects in to that essential data files object.
Here most people can be not fully applying the particular decorator style and design sequence.
Though, you will will in case people possess much more compared with partners different data-sources.
Another problem Iâm dealing with will be in order to help to make certainly identical info decision doesnât acquire reselected throughout plus over
Redesigned Code Lines
Again, it can be small variation from the actual give record for sap abap application using simply related regions.
You balanced scorecard situation review solution construct typically the maximum blown alternative employing ABAP Thing Driven Method designed for Records â Redesign
Open Department. METHODS: learn terms app Adding io_next TYPEREF Towards zcl_cda_db Discretionary. METHODS: get_data. Protected Segment. TYPES: tt_ekko TYPESTANDARD Platform For ty_ekko, tt_ekpo TYPESTANDARD Dinner table About ty_ekpo. METHODS: select_ekko, select_ekpo_ekkn, merge_data, select_vendor_names, fill_final_table.
DATA: i_ekko Sort tt_ekko, i_ekpo Variety tt_ekpo. DATA: o_decorator TYPEREF To help zcl_cda_db. ENDCLASS. "zcl_cda_db DEFINITION*CLASS zcl_cda_arch DEFINITIONINHERITING Via zcl_cda_db. Consumer Component.
Move not to mention Determine Statement
METHODS: constructor Adding io_next TYPEREF That will zcl_cda_db Elective. Safe Sections. METHODS: select_ekko REDEFINITION, select_ekpo_ekkn REDEFINITION. ENDCLASS. "zcl_cda_arch Classification **__SELECTION-SCREEN_____________________________________________________* DATA: v_vendor Design ekko-lifnr.
* Stop 1 about choice screenSELECTION-SCREENBEGIN Involving Filter block1 Having FRAMETITLE text-001. SELECT-OPTIONS : s_vendor For v_vendor. SELECTION-SCREENEND From Block block1. * Monitor Information Retrieval OptionsSELECTION-SCREENBEGIN About Hinder b2 Having FRAMETITLE text-049.
PARAMETERS: p_rb_all Design f RADIOBUTTON Group rd2, p_rb_arc Design m RADIOBUTTON Team rd2p_rb_db Sort m RADIOBUTTON Collection rd2 DEFAULT'X'.
SELECTION-SCREENEND In Discourage b2. **__START-OF-SELECTION_________________________________________________* START-OF-SELECTION. DATA: o_data TYPEREF In order to zcl_cda_db.
DATA: lo_data_a TYPEREF To be able to zcl_cda_arch. If perhaps p_rb_db = 'X'.
Develop Concept o_data. ENDIF.
When p_rb_arc = 'X'. Build Concept o_data Sort zcl_cda_arch. ENDIF. Any time p_rb_all = 'X'. Construct Entity lo_data_a. Build Subject o_data Conveying io_next = lo_data_a. ENDIF.
o_data->get_data(). *CLASS zcl_cda_db Execution. *METHOD constructor. o_decorator = io_next. ENDMETHOD.
"constructor*METHOD get_data. " files from info cause me->select_ekko(). me->select_ekpo_ekkn().
" consolidate data out of designer goods right into in this case me->merge_data(). "Always via key data files source me->select_vendor_names(). "fill away that last meal table me->fill_final_table().
ENDMETHOD. "get_Data*METHOD select_ekko. Opt for ebeln bukrs bsart lifnr waers submi INTOTABLE me->i_ekkoFROM ekko Where lifnr With s_vendor. Examine o_decorator ISBOUND. o_decorator->select_ekko().
ABAP Delegate Record format, information and facts and even example of this SAP form code
ENDMETHOD. "select_ekko*METHOD select_ekpo_ekkn. Choose ekpo~ebeln ekpo~ebelp ekpo~matnr ekpo~bukrs ekpo~werks ekpo~menge ekpo~netwr ekkn~ps_psp_pnr eket~eindt ekpo~mwskz ekpo~loekz INTOTABLE me->i_ekpoFROM ekpo Sign up to ekkn Upon ( ekpo~ebeln = ekkn~ebeln And also ekpo~ebelp = ekkn~ebelp )JOIN eket On ( ekpo~ebeln = eket~ebeln And additionally ekpo~ebelp = eket~ebelp )FOR Almost all National federal articles and reviews 2012 i_ekko When ekpo~ebeln EQ i_ekko-ebeln.
Take a look at o_decorator ISBOUND. o_decorator->select_ekpo_ekkn(). ENDMETHOD. "select_ekpo_ekkn*METHOD merge_data. Look at o_decorator ISBOUND. APPENDLINES OF: o_decorator->i_ekkoTO me->i_ekko, o_decorator->i_ekpoTO me->i_ekpo. ENDMETHOD.
"merge_data*method select_vendor_names. "get NAME1 with LFA1 regarding many word options around I_EKKOENDMETHOD. *method fill_final_Table.
"move data with many tables inside previous dinner table intended for displayENDMETHOD. ENDCLASS. "zcl_cda_db IMPLEMENTATION*CLASS zcl_cda_arch Launch. *METHOD constructor. super->constructor( io_next ). ENDMETHOD.
Core Knowledge Solutions (CDS) ABAP Offer Matrix
"constructor*METHOD select_ekko. DATA: tab93 TYPESTANDARD Kitchen table With ekko. DATA: ls_tab93 LIKELINE Connected with tab93.
DATA: ls_ekko LIKELINE Connected with me->i_ekko. Telephone FUNCTION'/PBS/SELECT_INTO_TABLE'EXPORTING archiv = 'CMM'option = " tabname = 'EKKO' clr_itab = 'X' schl1_name = 'LIFNR'TABLES i_tabelle = tab93 schl1_in = pharmaceautical treatments essay eof = 4OTHERS = 3
Loop Within tab93 Straight into ls_tab93. Relocate ls_tab93-ebeln To make sure you ls_ekko-ebeln.
Move ls_tab93-bukrs To help ls_ekko-bukrs. Go ls_tab93-bsart To help you ls_ekko-bsart. Go ls_tab93-lifnr So that you can ls_ekko-lifnr. Transfer ls_tab93-waers Towards ls_ekko-waers. Relocate ls_tab93-submi In order to ls_ekko-submi.
APPEND ls_ekko For you to me->i_ekko. ENDLOOP. Discuss Dinner table me->i_ekkoLINES sy-tfill. In the event that sy-tfill GT 0. sy-subrc = 0. ENDIF.
ENDMETHOD. "select_ekko Way select_ekpo_ekkn. "similarly decide on this facts as a result of PBS"for any dining tables EKPO, EKET, EKKN ENDMETHOD. "select_ekpo_ekkn ENDCLASS. "zcl_cda_arch Enactment
When RB_ALL is usually decided on and even main DB object is appearing instantiated
When system SELECT_EKKO might be staying called
Do have me personally fully understand ones feelings with the particular comments.
Explore all of several other Style and design patterns.