Skip to Content
Author's profile photo Former Member

Less is More: Modeling Calculation Views in Web IDE SPS09

In teaching you have about 10 seconds to gain 2 minutes of your captive audience’s attention. This video for the SAP HANA Academy by Tahir Hussain Babar aka Bob on Modeling Calculation Views in Web IDE does that and more.  More is the next two minutes which sets the scene for your next seven minutes which include an introduction, demonstration and the setting of objectives.

Picture1.png

In this video Bob demonstrates building calculation views within the Web IDE.

User Rights

To build calculation views you need to have the right to execute a package called Grant Activated Role. This is normally allocated to the Developer user but as the focus of this tutorial is actually building calculation views, the building of the Developer user will be the subject of another video.  This tutorial uses the System User with the same right allocated to it.

Please remember that this use of the System User is just to keep the tutorial focussed on building calculation views.  It is not standard practise.

Picture2.png 

Once the right has been assigned to the user you can shut down your SQL console and launch Google Chrome.  Type in the link shown and log in as the relevant user.

Picture3.png

The SAP based development workbench is now based upon core libraries as the SAP Web IDE.  There’s a new visual design and integration of some the web tools of the SAP Web IDE.  You also have access to SAP HANA Answers.

Building a Package

Bob then describes the step of building a package.  The steps for which are illustrated below.

Picture4.png 

  Picture5.png

Building a Calculation View

Only graphical and scripted calculation views are supported in the Web IDE.  You can’t build analytical or attribute views.   The illustrations below show this process a step at a time.

 

Picture6.png

  Picture7.png

In this example, Bob uses a table in a schema called surprisingly enough, Bob’s data.  He uses this moment to reinforce the point that only graphical or script based calculation views are supported.  He also reminds the viewer that some other features like unioning are not supported so you need to be careful what you want to do in those graphical calculation views.

Picture8.png

There are a few options such as joining, converting from projection or to aggregation and using dimensions or cubes that are just like in SAP HANA Studio.

Adding a Data Set

Bob then demonstrates adding a data set by searching the repository for a table called Employee.

Picture9.png

The Employee table consists of four columns only two of which ROLE and SALARY are going to be added to the output columns.

To build a basic calculation view you need to select Semantics.   When you go to Semantics you can see that it automatically chooses the measures and dimensions.   Once you have saved the view it is also activated ready for you to view the data.

When you click on the play button to view the Semantic you can see two things.   One of them is the SQL statement which the view executes and the other is the result on the bottom part of the screen.  You can also export the data and change the layout.

Picture14.png

Building a Scripted Calculation View

This starts in a similar way to previously.

Picture15.png

As in SAP HANA Studio you can choose either the view is going to be Parameter Case Sensitive.  Bob then demonstrates this by using a simple SQL statement. The same as the one used before.

  Picture16.png

As was demonstrated previously you now need to choose the columns that you want to output.  On the right hand side you can choose your columns.   Remember you need to put a semi-colon after the column so you can choose the data type. All you need to do now is activate and then view the data.

SAP HANA Studio

The views that have been created are not exclusively held in the Web IDE , you should also be able to see them and view the data in SAP HANA Studio.  This is shown below.

Picture17.png

Conclusion

As we have become busier our attention spans have become smaller.  Exposure to highly interactive presentations has made us blase about fancy animations and graphics. I really like this video because it gets you to the point quickly and does not waste precious time.  Having been part of a technical audience, I just want to know how to use whatever technology I am researching works, as soon as possible.  I don’t want to wait six months for a range of marketing people to make an epic presentation that is out of date almost as soon as it’s released.  As I found in teaching, over prepared lessons are often the worst.  Teaching like making instructional videos is a fine balancing act with time being the most valuable traded commodity.  This video has got that balance just right.

Assigned Tags

      Be the first to leave a comment
      You must be Logged on to comment or reply to a post.