Vous êtes sur la page 1sur 12

IMPLEMENTINGCALCULATED COLUMN INSIDE A ATTRIBUTE VIEW

Calculated Column:
It is an additional column which can be created by us, the results of which are calculated at
runtime based on the existing column and using functions, input parameters and constants.

Go to remote desktop connection<start<click on saphana studio

Right click on sub package<new<click on attribute view


Provide name as AT_COMPANY CODE<provide label<click finish

Click on plus icon add objects


Select T001 table

Select required output columns


Again Click plus icon<add TVKO table<click ok

Join T001 BUKRS to TVKO BUKRS<join type as inner join <select required output columns
Again click on plus icon<add TVKOT table<click ok

Join TVKO VKORG to join TVKOT VKORG<join type as text join<language as spras<<select
vtext
Again click on plus icon<select TCURT table<click ok

Join T001 WAERS to TCURT WAERS<select LTEXT<join type as text join<language as spras
Click on semantics<select BUKRS as key column

Provide descriptive mapping:

We can choose to associate an attribute with another attribute description. Label

Mapping is also called as description mapping. For example if a1 has a label column

B1, then you can rename b1 to a1.description. The related columns appear side by Side during
data preview
Click save and validate<click save and activate

Assign a object to change<click finish

Open data preview <click on raw data


Right click on calculated columns<click new

Provide name<provide label<provide length

Enter expression<click on columns <select required columns


Here we can see various functions available categorized into different sections like
 Conversion Functions
 String Functions
 Mathematical Functions
 Date Functions
 Misc Functions

Click on validate syntax<click ok


Click ok

Save and validate<save and activate

Click on data preview<click on raw data


By this we can say that calculated columns are very useful in SAP HANA and has good amount
of functions that can be used to build the same. If we need any help on the syntax of the function
or how different functions works, we can use the symbol ‘’ in calculated column editor screen

Vous aimerez peut-être aussi