Semantic Tags
Semantic Tags
Semantic Tags
PUBLIC
Warning
This document has been generated from the SAP Help Portal and is an incomplete version of the official SAP product
documentation. The information included in custom documentation may not re ect the arrangement of topics in the SAP Help
Portal, and may be missing important aspects and/or correlations to other topics. For this reason, it is not for productive use.
This is custom documentation. For more information, please visit the SAP Help Portal 1
8/3/2022
Semantic Tags
Semantic tags are short text identi ers that you use to represent key gures. They are assigned to structures of nancial
statement versions (FSVs) or G/L account hierarchies to simplify calculation of measures and KPIs for analytical reports.
You can also assign additional semantic tags to structuring elements of FSVs, such as to FS hierarchy nodes and G/L accounts,
so that the system can determine and display correct results in nancial statements, such as balance sheets, income
statements, and cash ow statements. Examples are as follows:
2. Expand the path Financial Accounting (New) General Ledger Accounting (New) Master Data G/L Accounts Balance
Sheet/Pro t and Loss Structures Semantic Tags for Balance Sheet/Pro t and Loss Structures .
4. Choose New Entries and enter the semantic tag group ID and description.
This is custom documentation. For more information, please visit the SAP Help Portal 2
8/3/2022
Note
This process is not required if the semantic tag groups SAP delivers meet your needs. However, to use your KPIs across
several applications or business areas, you may want to de ne your own semantic tag groups, for example Pro tability or
Cash Flow Statement, to organize semantic tags.
2. Expand the path Financial Accounting (New) General Ledger Accounting (New) Master Data G/L Accounts Balance
Sheet/Pro t and Loss Structures Semantic Tags for Balance Sheet/Pro t and Loss Structures .
4. Choose New Entries and enter an ID, a long and short description for the new semantic tag.
Note
This process is not required if the semantic tags SAP delivers meet your needs. If you want to de ne your own semantic tags,
to apply the semantic tags to analytical reports, you will need to extend the standard CDS views and create your custom
queries with the new semantic tags. For more information, see Extending/Creating Queries with New Semantic Tags.
FSVs can be created using Customizing for De ne Financial Statement Versions (transaction OB58) or the Manage Global
Hierarchies. For these two types of FSVs, semantic tag assignment works differently:
2. Expand the path Financial Accounting (New) General Ledger Accounting (New) Master Data G/L
Accounts Balance Sheet/Pro t and Loss Structures Semantic Tags for Balance Sheet/Pro t and Loss
Structures .
4. Select New Entries and choose whether to assign the semantic tag to the Financial Statement Item, G/L
Account, or Functional Area.
5. Map the semantic tags to elements of an FSV by specifying values for FS Version, FS Item (or G/L Account or
Functional Area depending on your choice in last step), and Semantic Tag.
The following animated GIF demonstrates how to assign semantic tags to FS items:
This is custom documentation. For more information, please visit the SAP Help Portal 3
8/3/2022
Note
You can also use the Assign Semantic Tags to FSV app from the SAP Fiori launchpad to make the assignment same
as above.
For FSVs created with the Manage Global Hierarchies app, the semantic tag assignment is made directly within the app.
For more information, see De ne Financial Statement Versions in Global Hierarchies.
Related Information
Assign Semantic Tags for Cash Flow Statement
The following sections describe both procedures, taking the CDS view/query for cash ow statement (indirect method) as an
example.
2. Open the CDS view. Replace view_name with the standard CDS view you want to extend, in our example,
C_CashFlowIndirectIFRS.
3. Replace data_source_name.element_name with the new measure eld de nition, for example:
@DefaultAggregation: #SUM
@Semantics: { amount : {currencyCode: '$projection.CompanyCodeCUrrency'}}
@EndUserText.label: 'Income Tax'
This is custom documentation. For more information, please visit the SAP Help Portal 4
8/3/2022
case SemanticTag
when 'ZINCOMETAX' then AmountInCompanyCodeCurrency
end as ZZ_IncomeTaxInCCCry
The sample code adds the eld ZZ_IncomeTaxInCCCry (labeled Income Tax) to the standard CDS view (and any
analytical queries that are based on it). The eld sums up all amounts of the FS items or G/L accounts that are assigned
with your new semantic tag ZINCOMETAX. Only amounts in company code currency are relevant.
4. Activate the extended CDS view. A full example of the extended view is as follows:
As a result, the new measure eld is now available in all reports that consume the extended CDS view, in our example, the
Design Studio report Cash Flow Statement - Indirect Method.
Note
The app can only be accessed by the users assigned with role Analytics Specialist
(SAP_BR_ANALYTICS_SPECIALIST) or business catalog Analytics - Query Design (SAP_CA_BC_ANA_AQD).
2. Open the query. Make any necessary changes in the General tab, such as the query label.
3. Go to the Display tab and choose Add Add Restricted Measure to add a eld to the query. In the dialog box, enter the
label text and ID for the eld.
4. On the New Query Field panel, make the following required changes:
b. In the Fixed Values section, choose Add Restriction and select Semantic Tag as the dimension that will appear in
Fixed Value For. Add "= <your new semantic tag>" as an Include lter. Note that you also need to remove the
default restriction.
In this way, the new eld is created. By default, it sums up all amounts of the FS items or G/L accounts that are assigned
with your new semantic tag. You also choose Up or Down to change its position in the query.
Note
If you want to de ne any calculation logic between existing measures and the elds assigned with your semantic tag,
you also need to add a calculated measure with formula and function de nitions.
7. Additionally, if you want to provide the query as an app tile to business users, take the following steps:
b. Search for the query you created earlier and select it.
This is custom documentation. For more information, please visit the SAP Help Portal 5
8/3/2022
c. Choose Create Application Multi-Dimensional Report .
d. Enter the title and subtitle for the app. The application is created.
e. Choose Show Application Status. You are brought to the Custom Catalog Extensions app, where you can specify
the business catalogs in which you want to include the access to the application you created just now.
Example
You may add the business catalog SAP_SFIN_BC_GL_REPORTING, which is part of the business role General
Ledger Accountant (SAP_BR_GL_ACCOUNTANT). In this way, any business users that are assigned with the
business catalog can access the application you created.
f. Choose Publish.
After the status changes to Published, the relevant business users can access the app (a Design Studio report)
from their Fiori launchpad (or nd it in App Finder).
Note
A G/L account may be assigned with multiple semantic tags assigned. Therefore, in your custom CDS view or analytical
query, restriction by semantic tag (or using "restricted measure") is required to avoid displaying duplicate values in the
relevant reports.
Related Information
CDS Views for Finance
Custom Analytical Queries
This is custom documentation. For more information, please visit the SAP Help Portal 6