1 2 3 7 Previous Next

SAP NetWeaver Business Warehouse

100 Posts

I have seen a lot of posts asking for standard tables behind BW objects. I hope to clarify this with this blog. Actually an object is transported between two BW system by transporting the table entries of standard table associated with the object. Let me show you how to see the standard table behind a DSO.

 

1) Collect any DSO in a transport request

TR.JPG

 

2) Double click on the TR to get the below screen

 

TR1.JPG

 

3) Double click on the line corresponding to the DSO or Right click on the line and press display . You will get the list of tables associated with DSO.

 

Table.JPG

Thus you can get all the tables associated with the DSO. You can see the description of the table in SE11 to know what is stored in these tables and find the table you are looking for.

 

You can see all the tables associated with any BW object (Cube,infoobject, Multiprovider, transformation etc) by following the above technique.

Standardization is a key aspect of SAP BW Layered, Scalable Architecture (LSA), SAP’s best practice in Enterprise Data Warehousing. One of the ways to realize standardization in the data staging process is developing generic, reusable ABAP building blocks with a comprehensive interface.

From an Enterprise Data Warehousing perspective, the process of Data Unification can be classified as a modeling pattern. The Data Unification Services' ABAP building block and central control tables are designed to standardize and facilitate this process.

In this blog I will discuss Data Unification Services, the concept behind it and how to use it in the transformation.

I developed a working version of the Data Unification Services which I am going to share via a document. It will cover all details on creating the ABAP Objects classes, including the source code and all necessary ABAP Workbench objects.

Conceptual Overview

Data Unification in an LSA context is all about supplementing data records with administrative characteristics. Usually it concerns the following characteristics:

  • Data Domain;
  • Organizational Unit;
  • Request ID;
  • Timestamp;
  • Origin.

 

Data Domain is related to domain partitioning or strategic partitioning and is applicable to transactional data flows. Please refer to my blogs Pattern-based Partitioning using the SPO BAdI - Part 1: Introduction and Pattern-based Partitioning using the SPO BAdI - Part 4: Use Cases for more information.

Domain partitioning is not always applicable: Data Acquisition Layer, Corporate Memory Layer and master data flows in general. In these cases it's transparent to assign data to domain 'X' (cross-domain and domainless).

 

Data Unification Services is positioned in the Harmonization & Quality Layer.

 

Figure_1_Positioning.jpg

Figure 1: Positioning in LSA (source: SAP AG)

 

The following figure shows an example of an LSA compliant transactional data flow.

 

Figure_2_Data_Flow.jpg

Figure 2: Data Unification Services in the Data Flow

 

The yellow callout indicates where Data Unification Services is implemented. The transformation is positioned between the Data Acquisition Layer outbound InfoSource and the Harmonization Layer Pass-thru DSO.

For other data flows it is slightly different. In master data flows the transformation is positioned between the Data Acquisition Layer outbound InfoSource and the Harmonization Layer intermediate InfoSource. In Corporate Memory flows the transformation is positioned between the Data Acquisition Layer outbound InfoSource and the Corporate Memory DSO.

Note that in all cases this transformation is exclusively used for Data Unification Services.

Control Tables

For transactional data flows the basic rule is that domain partitioning is applied. Data Unification Services needs help to be able to determine Domain and Organizational Unit automatically. Therefore we have to introduce 3 control tables.

Exclusively for transactional DataSources the following control tables have to be maintained:

  • YBWUNISRC - Domain Driving Source Field DataSource;
  • YBWUNIVAL - Value Assignments;
  • YBWUNIREF - Reference Domain Driving Characteristic.

 

Table YBWUNISRC is always mandatory to be maintained for every new transactional DataSource. It is used to store the domain driving source field of the DataSource and the corresponding InfoObject.

 

Figure_3_Domain_Driving_Source_Field_DataSource.jpg

Figure 3: Control Table - Domain Driving Source Field DataSource

 

Table YBWUNIVAL is used to store the value assignments. It has to be maintained less frequently since already existing value assignments can be reused. E.g. InfoObject Company Code and its characteristic values are already maintained. Every next DataSource can reuse these value assignments, there is no need to maintain them more than once. There might be a future need to maintain the entries if new Company Codes are introduced.

 

Figure_4_Value_Assignments.jpg

Figure 4: Control Table - Value Assignments

 

In some cases you might encounter that multiple InfoObjects are used for the same entity. In such cases it must be avoided that the value assignments are entered more than once. That is why the reference domain driving characteristic functionality was introduced. Table YBWUNIREF is used for this purpose.

 

Figure_5_Reference_Domain_Driving_Characteristic.jpg

Figure 5: Control Table - Reference Domain Driving Characteristic

Using Data Unification Services

Prerequisite for using Data Unification Services is the presence of the administrative characteristics in the target structure of the transformation. I.e. you have to add these characteristics to the DSO or InfoSource (depending on the data flow). The example below shows a DSO where you have to add the characteristics to the Data Fields section.

 

Figure_6_Adding_Administrative_Characteristics.jpg

Figure 6: Adding Administrative Characteristics to DSO

 

The Data Unification Services building block is realized as an ABAP Objects class. One of the following public methods has to be called in the transformation (end routine or expert routine):

  • EXECUTE_END - Execute Transformation End Routine;
  • EXECUTE_END_X - Execute Transformation End Routine (Only Domain 'X');
  • EXECUTE_EXPERT - Execute Transformation Expert Routine;
  • EXECUTE_EXPERT_X - Execute Transformation Expert Routine (Only Domain 'X').

 

You can see in the screenshot below an example of the limited source code to be entered here.

 

Figure_7_Coding_Example.jpg

Figure 7: Example of Data Unification Services in the Transformation

 

The source code can easily be inserted by using the appropriate ABAP Pattern. Click on push button Pattern, choose option Other Pattern and select the appropriate pattern in line with the type of routine (end routine or expert routine) and domain.

 

Figure_8_ABAP_Patterns.jpg

Figure 8: Inserting the Data Unification ABAP Pattern

 

The following ABAP Patterns are available:

  • YBW_END_UNI - Execute Transformation End Routine;
  • YBW_END_UNI_X - Execute Transformation End Routine (Only Domain 'X');
  • YBW_EXPERT_UNI - Execute Transformation Expert Routine;
  • YBW_EXPERT_UNI_X - Execute Transformation Expert Routine (Only Domain 'X').

 

All Data Unification functionality is provided by the class. The source package and/or result package are processed dynamically. The relevant information is fetched from the control tables. Any exceptions are handled appropriately: they terminate the process in a controlled way and fill the monitor log with information on the errors.

Conclusion

From an Enterprise Data Warehousing perspective, the process of Data Unification can be classified as a modeling pattern. The Data Unification Services' ABAP building block and central control tables are designed to standardize and facilitate this process.

In this blog we discussed Data Unification Services, the concept behind it and how to use it in the transformation.

Introduction

 

Many of our SAP BI/BW Consultants may not have OSS Id to browse SAP Notes at Market place. The following steps will show you How to download Notes without OSS Id..

 

Step 1: Goto t-code SNOTE in Dev system, you will get the screen like below

 

Snote.JPG

Step 2 : Click on Goto -->Download SAP Note

Step 3 : Enter the Note No. and Press Execute

Step 4 : At times, You may get Error in RFC connection. You can ignore this message and try again

Step 5 : Your SAP Note will be downloaded and available under SAP Notes-->New. You can refer the screen shot

 

These simple steps will make you to get any SAP Notes

Pre requisites: The reader understands and has extensively used APDs. Yoou just need the basic knowledge of an APD.

 

1. APD's are not designed to work with large amounts of data. Make sure you are filtering out all the data that is not needed, let us say you need to quickly dig into  past 2 months of invoices data-> do not pass all your historical invoices data through your APD.

 

2. Remove the option in the performance settings- > process in memory, if the data amount is still large enough -> 2 months of invoices data is big

 

3. Try to schedule the APD as a background job through the program- > RSAN_PROCESS_EXECUTE.

 

4. If you are using the infocubes or multicubes as your apd source, try partitioning the Infocube and compressing the requests, if the apd has to mine 2 months of data from f- table it has to query on all the requests, instead of the partitions (calmonth or fiscper)

 

5. table partitioning and compression, is a recommended practice, as a part of administration, which would also improve your apd performance.

 

 

Next Blog: To be determined..

What if you accidentally delete a custom program/ function module:

 

Program:

Go to Tr: SE38

Type in your program name same as earlier name-> save and activate the empty program -> go back to the SE 38-> Go to Utilities -> Version management -> Check the recent version than your current one -> Retrieve.

 

Function Module: Tr: SE37

Type in your FM name same as your deleted one-> save it to the same function group as before without any code-> come back to the SE37-> Go to Utilities -> Recover your old version.

 

You could also do a remote comparison in your code between two systems. Between development and test system, or test system and production system.

 

This is strictly recommended for transportable objects only.

 

Next Blog: Theoretical approach to improve the performance of the APDs

The activation operation of a standard data store object (DSO) in BW 7.30 on HANA has been optimized for HANA. It has now all the performance advantages of the HANA-optimized DSO which has been originally shipped and that required an explicit conversion step during the migration to BW-on-HANA. This is now obsolete. Also, older data flow setups can now benefit from some of the advantages. The necessary changes are planned to ship with BW 7.30 SP10 and HANA revision 56. Alternatively, BW 7.30 installations on SP8 or SP9 can apply code changes offered in OSS note 1849497. In summary, this yields a significant simplification.

The availability of the active and not-active data concept in HANA allows to maintain a materialized change log of the standard DSO at no impact on main memory consumption. It is even more efficient as the (on the fly) calculated change log of the HANA-optimized DSO consumes quite some memory at the moment it is accessed. So overall, the reworked standard DSO provides all the advantages and requires no conversions. As a consequence, the HANA-optimized DSO becomes obsolete. It will still be supported. So don't worry if you are using this type of DSO. It continues to work as before. A re-conversion tool will be provided in June. Details can be found in this document.

 

This blog is cross-published here. You can follow me on Twitter under @tfxz.

In some cases, adding custom buttons simplify navigation .Ex: After executing the query, when the user needs to rerun the report, the variable screen needs to be navigated in two-step process 1) Right click on Filter and 2) click on Variable Screen as shown below:

1.png

Steps to add custom button to repor to ease navigation:

1)  Insert Button group from standard web item tab to the report layout2.png

2) Name the button and set button property by clicking ” .”  icon under internal display

3.png

3) Wizard for parameter for web item opens up:

4.png

4) Edit the caption, select “Command via Wizard” in action and select “ OPEN_VARIABLE_DIALOG” command and click OK.

5.png

5) Result: By clicking the variable screen custom button.

6.png

7.png

Similarly we can add buttons for other options available from Context menu properties. Ex Bookmark, Export to PDF , Export to Excel etc..


After executing report in WAD (Web Application Designer), we see lot of options enabled on right click of report data as shown below

1.png2.png

Requirement is to keep only required right click option for the end users:

Steps to restrict or to select only required options:

1)  Insert Context menu web item from Miscellaneous tab to the Web template Layout

3.png

2) On the property tab for Context Menu, select only required options. Undo/off Broadcast and currency translations.

4.png

3) Save and execute the report.

4) Displays result data with removed navigation – Currency translation and Broadcast.

5.png6.png

Note: Context menu web item is just the behavior of the web report and will not get displayed like other web items.

 

  In some scenarios, these options helps to avoid confusion to end users since most of the time calculations and translations are implemented as part of query design and broadcasting is restricted to power users .

 



We all know that BW Cubes are based on extended start schema. The extended star schema is a more updated version of Classic Star Schema where the Dimension Tables in place of keeping actual data within them , keep SID values. These then further refer to the Master Data SID Tables (S,X,Y).

 

This keeps the actual Master Data values out of the limit of just one cube and is then available to multiple cubes.

 

Start_Schema.JPG

But, how Navigational Attributes are placed in this Extended Star Schema Model. Also, when we talk about Navigational Attributes we do understand that too much of the same is not good for performance point of view. But how...this the million dollar question?

 

Let us first see one illustration below, this focusses on only one of the many master data connections (any one of them) and which is connected to any of the Dimension Table. We have not considered time dependent Navigation Attribute here.

 

Navigational_Attribute.JPGSuppose the master data here is "Customer Master" data. This is not time dependent and has three attributes within marked as Navigational attributes.

We again focus for illustration on one of the objects "Partner" which is again a master data object with certain other objects as Navigational Attributes.

 

This makes SID table for both these objects (Customer & Partner) as X table.

 

Now as we see if we have any object marked as Navigational in any masterdata we end up generating:

  • SID field entries for them in Naviagtional SID Table (X or Y)
  • We have additional joins here which increase complexity (the blue table connections)

 

So think about how many additional such connections SIDs for one Master Data if we have so many objects marked as Navigational Attributes.

 

Hope this puts some light on the same 

Bex Query: Formula variable using Replacement Path:

 

We can create formula variable at the bottom of the available operands (key figures listed).

Then assign it to a calculated key-figure or local formula.

 

 

slide26.png

 

 

Requirement1: To calculate Sales per No. of seats.

 

Sales value is coming as key figure

No. of seat(characteristic) is attribute of Profit Center and has data-type as NUMC length (4).  

We can not use characteristics in the calculated key figures or in the local formula.

and We need to get the attribute value w.r.to characteristic value of Profit Center (0PROFIT_CTR).

We will convert it into number using formula variable.

We have selected ref. char. as Profit Center and attribute as No. of Seat.

 

 

slide20.pngslide21.png

 

slide22.pngslide23.png

 

 

No of seat has mapping with profit center. We will do exception aggregation with profit center.

Now we can use this CKF to get Sales per Seat.

 

slide13.png

slide14.png

 

Output1: slide27.png

  If we use result as summation for Sales per seat, result will be like below:

slide28.png

 

Output2:slide29.png

 

 

 

Another Scenario: Requirement2:

1.  

         To get term in days = Maturity date(End of Term) – Start date. Where dates are available as characteristics.

         We can create formula variable using replacement path and data-type as date. Create one formula variable for Maturity date and one for Start Date.

         Note the info-object in the reference characterisitcs of general tab.

         for e.g.: total term period, remaining term period can be required in case of Insurance where we have Maturity date,

         start term date, As-of date(evaluation date).

 

slide07.png   slide08.png

 

slide09.pngslide10.png

 

Either create Calculated key figure or create a local formula (key-figure Section) to get term in days.

 

slide16.png

 

slide17.png

 

slide19.png

 

 

 

  In   In Requirement1: we have converted info-object:attribute value to number,

        In Requerement2: we have converted Info-object:key value to date.

     

 

        thanks& regards,

        Vikas

 

      ---

 

 

In

From long time I was looking for BEX query comparison tool but I did not get anything and after long efforts I got one idea to compare Bex Queries in Different client.

And I wanted to share this with all of you.

 

 

Capture1.PNG

Many times queries are modified in production directly which create problem to keep queries in sync.

 

First of all I want to say it may not 100% accurate to compare Query in different client/system but it is boon to reduce your manual comparison of Query.

Let’s start with “How to Compare Query in Different client/system?

Let’s have scenario here you want to compare Query from PROD TO DEV then

 

Go to PROD and enter Tcode RSRTQ

 

Capture2.PNG

 

Enter Query name as follows and execute

Capture3.PNG

You will get all query definition as follows then click on Download(F9)

Capture4.PNG

Capture5.PNG

Click on ok…

 

Capture6.PNG

 

Then Go to  System -> List -> Save -> Local File

 

Capture7.PNG

Capture8.PNG

Press OK.

Then Create one text file in Notepad say PROD300.txt and paste and save.

 

Capture9.PNG

Similarly follow all steps in DEV also and create file DEV100.txt

Capture10.PNG

Now we will compare these two files using any Code Comparing Tools.

In my case I am using online Code Difference Comparison Tool .

Put you both code in Text pane 1 and 2 and compare.

 

Capture11.PNG

Then simply you can compare both queries from PROD & DEV as follows.

Capture12.PNG

Capture13.PNG

Hope this document will be helpful to the readers.

Vikas Gautam

beginners blog to SAP CRM

Posted by Vikas Gautam Apr 16, 2013

SAP CRM

 

 

SAP CRM Marketing: Campaign Management, Lead Management

 

SAP CRM Sales: Sales Planning, Sales Order Management:

                  Sales: Opportunity -> Inquiry/Quotation -> Contract -> Order 

 

SAP CRM Service: Service Order Management : Complaint -> Service Request

                             

Advantages:   Improve customer service, Assess and motivate employees, Optimize Organization,

                      Reduced expenses,Effective processes, Improved turn-around-time.                       

 

Definitions:

 

1.   1. SAP CRM Marketing: The Marketing module helps you introduce a new product to existing and new customers and

        engage them through campaigns.

        After we identify a prospective customer (i.e. lead) group that would be interested in the product,

        we can automatically convert the prospect to an opportunity.

        We can use the Sales module to create the opportunity and generate a sales quotation for the customer.

        If the customer agrees with the quotation, we can then create a sales order.

 

1.   2.  SAP CRM Marketing: Using Segmentation tool, we can identify customers with similar interests and attributes

             and form customer segment groups or customer groups and the  process of grouping is known as Segmentation.

             for e.g. working class, students or retired people.

       With Segmentation  we can create more effective marketing campaigns and we can address

       the needs of customers better. It also helps in gathering data for analysis purpose.

 

3. SAP CRM Marketing: The Marketing programs, activities that are plan, run and tested to generate awareness

              among potential customers are defined as Campaigns. We can create campaigns to promote a product or

              service to your customers. These marketing activities include identifying customers, drafting the information

              we want to communicate and selecting the medium to transfer the information.

              We can run campaigns by using telephone, advertisements, e-mail or SMS.

        Apart from promotion of product,we also get feedback from customers.

 

4. Organizational Data: represents Internal view of organization

      As we have in ECC, Sales structure: Sales Organization, Distribution channel, division

      CRM side, we have Organization attributes:

      Sales Organization, Sales office, Sales Group, Service Organization

      General attributes:

      Country, Division, Distribution channel, Postal code, Region.

 

Picture4.png

 

3.   5. Business Partner: contains relationship mapping:

  •   Employee, Vendor, Customer, associated parties 

  •   Can be an individual or organization

  •   Sold-to-party, Ship-to-party, Bill-to-party, Payer

  •   Contact Person, Employee/Personnel responsible or (Field Sales Representative).

  •   A Contact/Prospect may or may not be a Customer.

•       Picture3.png

 

4.    6. Territories:  Reflects Market View of an organization

  •  are defined w.r.to business unit, business partner, product, field sales representative, region, country

  •  Territory Management can be used to distribute or classify data correctly.

  •  Reporting is done on Customer/Product/Region.

  •  Reporting is also done on ORU/MRU(Organization reporting unit or Management reporting unit – structure or hierarchy).

 

7.  Master data: e.g.  

Organizational mapping data, Territory information, Region information , Business Partner Information, Material or Product, Address, Region

Territory(0CRM_TR), Business Partner(0BPARTNER), Business Partner: CRM Sales View (0CRM_BP_SAL),

Sales Office(0CRM_SALOFF or 0SALES_OFF), CRM Sales Group(0CRM_SALGRP), Region(0Region),

Organizational Unit(0ORG_UNIT or 0CRM_SALORG), Product(0CRM_PROD), Prospect(0CRM_PROSPE),

Origin Opportunity/Lead(0CRM_SOURCE).

 

Transaction data: e.g. Sales data, Stock data, Billing, Deliveries .

       Tables: CRMM_TERRITORY, CRMM_TERRITORY_T.

 

thanks & regards,

Vikas

 

----

Hi

 

I'm gonna explain how to debug the background job in SAP BI. For instance if your background active job got stuck or if its taking a long time. And you need to debug the concern job.

 

First debugging the background job in SM37. For anything you create or trigger there will be the background instance or job will be created.

 

1 . SM37, Select any active job and type this "JDBG" in command line and enter it will take you the ABAP degubber mode.

 

sm37.png

2. Debugging the dialog job. Go to SM50 where you see the list of process status running, On hold , waiting and you want to debug the particular running job. Select the PID on top Administration>> Program >> Debugging. After that a Pop will confirm for the debug mode . Click yes.

 

SM50.png

Hi All,

When a DSO failed with an error message as "Error during assignment of request ODSR_XXXXXX to partition..." "PSA update failed" "Process returned with errors", here is the way how to resolve the issue...

Error Message:

Error during assignment of request ODSR_XXXXXX to partition..." "PSA update failed" "Process returned with errors

Reason for the DSP Activation Failure:

 

 

Failed due to New Data Table inconsistency, hence we need to resolve the issue.

 

Most of the times, DSO activation failure can be resolved simply by repeating it. But whenever there is an inconsistecy withthe DSO's "New Data Table", repetition will not work. We need to follow the below process to activate the DSO.

Here is the error message:

p1.png

 

STEP:1 :- Go to RSRV, inorder to resolve the inconsistency..

pc2.png

STEP:2 :-  Give the PSA Table name (DSO's Change Log Table Technical Name)...

pc3.png

STEP:3 :-  Select "Consistency between PSA Partitions and SAP Admin Information

pc4.png

STEP:4 :- Execute

pc5.png

STEP:5 :- Select PSA and click on the " Correct Error", which will remove the correctable error..

pc6.png

STEP:6 :-

Check the log...

pc7.png

Which will give us the reason for the error correct it.

STEP:7  :- Repeat the step, hence the DSO activation will be completed successfully.

 

pc8.png

 

Please post your valuable comments and suggestions in case of any modifications required for this content.

 

Thanks,

Chandra.

Scenario: I came accross a scenario where the client wanted us to check for the number of records picked up during the full load.If the number of records were found to be zero, the load was to be terminated so that further loads do not happen as they would be incorrect if this load fetched zero records.

 

Solution: We created a program to check the number of records in table( in our case it was the PSA table) and terminate the process chain by using an error message if zero records were fetched. In our case, it was always a full load from ECC to BW, as it was a small table with limited entries and the table was supposed to be updated by a particular time in ECC  by the users'. There were other loads which were dependent on this load. so in case, this load did not fetch any records(because the table wasn't updated by the time process chain ran) other loads were supposed to stop.

 

The program:

 

REPORT  Z_CHECK_number_of _records.

DATA:
  o_ref TYPE REF TO data.
FIELD-SYMBOLS:
  <lt_table> TYPE STANDARD TABLE,
  <fs>       TYPE ANY,
  <field>    TYPE ANY,
  <field1>   TYPE ANY.
PARAMETERS:
  p_tab       TYPE tabname.       " Table name
  START-OF-SELECTION.
  CREATE DATA o_ref TYPE TABLE OF (p_tab).
  "ASSIGN p_field TO <field1>.
  ASSIGN o_ref->* TO <lt_table>.

  SELECT *
    INTO TABLE <lt_table>
    FROM (p_tab).
if ( sy-subrc NE 0 ).
  MESSAGE e213(/MAP/E).
endif.

 

 

When the program is run it asks for the name of the table for which the records are to be checked. Following is the screenshot of the selection screen:

Analyzer1.png

 

While using this in a process chain, this has be inserted before the step where you want to stop the process chain.

Create a variant of this program by entering the name of the table in the selection screen and saving it.

Now select the process chain variant ABAP Program and insert this variant of the program.

 

Now, when the process chain runs, it encounters this step and checks for the number of records and sends ou an error message if it finds zero records.

Filter Blog

By author:
By date:
By tag: