Skip to Content
Technical Articles
Author's profile photo Lucia Subatin

From zero to Analytics pt1: Setting up your own SAP HANA instance

This blog post is the first of a series showing how to go from zero to building analytics using SAP HANA and SAP Analytics Cloud.

The series will cover (even if pointing at existing source):

  • This same post: How to get your own on-premise SAP HANA instance with XS Advanced and how to configure it
  • Part 2: How to build (or clone) a calculation view with data privacy function
  • Part 3: How to create and configure a user to connect through external tools
  • Part 4: How to configure the HANA Analytics Adapter to consume models from tools such as Analysis for Office or SAP Analytics Cloud
  • Some KPIs (not exactly the sample dashboard in the picture above) to verify the installation

If you are looking to integrate the SAP HANA service on SAP Cloud Platform (Cloud Foundry) with SAP Analytics Cloud, check this series of blog posts instead:

Get you own instance of SAP HANA

You can get your own on-premise instance of SAP HANA for free even for productive use. In order to use the latest tools, you will need to download or deploy the full image.

By “full”, I mean the one that has XS Advanced and includes tools such as SAP Web IDE for SAP HANA. All of the installation options and instructions for HANA Express are here:, on the right side of the diagram BUT…

(I like big BUTs and I cannot lie...):

…this image needs at least 16GB of RAM though I would recommend 24GB for it to run smoothly and avoid network issues if using SAP Analytics Cloud.

If you are planning on using Analysis for Office locally, here is how to check the RAM memory in your Windows or Mac machine if you are unsure. You could run it locally and make it swap if your operating system allows it, but you have better chances of running it smoothly on any of the cloud providers.

What I would recommend as a starter

If you want to go the easy way, here are the easiest deployments on the Cloud providers:

Although they ask for your credit card for verification purposes, some cloud providers give you initial credits so the entire experience will be for free. Read the fine print, it probably says it will not charge you after you run out of credits.

Running in the cloud will also make it easier for you to access the instance from outside your network, like from SAP Analytics Cloud. Running locally on your computer will require further configurations (including network) that I will not be covering here.

I personally use a mix of cloud with a manual installation based on Ubuntu most of the time.

Tweak your instance

Access your instance from outside your network

If you are planning on connecting from SAP Analytics Cloud, you will need to be able to access your instance from outside.

By default, the host and XSA domain name in HANA Express is called hxehost. You are instructed to modify the hosts file in your computer to map hxehost to the IP of your instance. However, you cannot do this mapping in SAP Cloud Platform and any request coming from outside your computer will not find the host hxehost.

Here are the instructions for renaming your instance:…/

Prepare XSA to use the tenant database

SAP HANA has been multi-tenant for some versions. The tenant database is the one with the power to perform real SQL, so you will map the default Cloud Foundry space (development) to the first default tenant, called HXE.

The commands are as easy as:

xs enable-tenant-database HXE
xs map-tenant-database -o HANAExpress -s development HXE

Make sure the mapping has been successful. If it’s not and you continue to use the space, you will find out quite late in the process thanks to a scriptserver error.

Get the CLI for XS Advanced

If you are NOT using the command line from the operating system in your virtual machine, you will need to download the Command Line Interface for XSA.

If you do not have access to the SAP Service Marketplace, you can get it from the client package for SAP HANA, express edition. Here are the instructions:

You are now set for success. You can continue with the next blog post on how to create a calculation view:

And if you are celebrating, merry Xmas!


Lucia ( @LuciaBlick )

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Nabheet Madan
      Nabheet Madan

      Thanks Lucia for the blog, looking forward to the next in series.

      Author's profile photo Lucia Subatin
      Lucia Subatin
      Blog Post Author

      Thanks for reading and commenting, Nabheet  🙂

      Author's profile photo BDC ERP
      BDC ERP

      Thanks Lucia, can't wait to see "How to configure the HANA Analytics Adapter" !

      is that possible to login Analysis for Office using XSA application user ?




      Author's profile photo Lucia Subatin
      Lucia Subatin
      Blog Post Author

      Hi Jinni, yes, it works with Analysis for Office 🙂

      Author's profile photo Jing Shen
      Jing Shen

      Hi Lucia,

      I have posted a question about how to use XS Advanced Analytics Adapter,

      but no one answer so far, could you shed some light on it ?

      any information will be appreciated.





      Author's profile photo Petter Huseby
      Petter Huseby

      Great tutorial 🙂

      I have earlier configured CORS using HANA modeler. I just like to know if some of my earlier configuration steps are obsolete,espesialy if I need to install EPM-MDS addon

      1. Install EPM-MDS
      3. ALTER SYSTEM ALTER CONFIGURATION ('xsengine.ini', 'database', 'HXE') SET ('public_urls', 'http_url') = 'http://hana:8090'; WITH RECONFIGURE
      4. ALTER SYSTEM ALTER CONFIGURATION ('xsengine.ini', 'database', 'HXE') SET ('public_urls', 'http_url') = 'https://hana:4390'; WITH RECONFIGURE
      5. ALTER DATABASE HXE ADD 'xsengine'
      6. ALTER DATABASE SYS ADD 'xsengine'
      7. call _SYS_REPO.GRANT_ACTIVATED_ROLE ('sap.bc.ina.service.v2.userRole::INA_USER', 'SYSTEM');
      8. call _SYS_REPO.GRANT_ACTIVATED_ROLE ('sap.hana.xs.admin.roles::RuntimeConfAdministrator', 'SYSTEM');
      9. call _SYS_REPO.GRANT_ACTIVATED_ROLE ('sap.hana.xs.admin.roles::SAMLViewer', 'SYSTEM');
      10. call _SYS_REPO.GRANT_ACTIVATED_ROLE ('sap.hana.xs.admin.roles::HTTPDestViewer','SYSTEM');
      11. call _SYS_REPO.GRANT_ACTIVATED_ROLE ('sap.hana.xs.admin.roles::SQLCCAdministrator','SYSTEM');

      Petter Huseby


      Author's profile photo Petter Huseby
      Petter Huseby

      Just a followup:

      It seems that I don't need to do any of the steps I described. I have followed your guide, and are close to get the connection up and running. My last error is now: Bad gateway when I test the following url :

      Author's profile photo Lucia Subatin
      Lucia Subatin
      Blog Post Author

      Hi Petter,


      Most of the steps you mentioned above apply only to the INA connector for XSC ( ).

      For a “bad gateway” using the steps in this blog post series (using XSA), I would check the logs for the xsahaa-java and xsahaa-entry apps.



      Author's profile photo Petter Huseby
      Petter Huseby

      Thanks Lucia. One og the services was not running, and that was the cause of the bad gateway error. Greate blog. Not easy to find information about this topic.

      Author's profile photo Abigail Rowe
      Abigail Rowe

      Core to you soon Male, Hana modeler. If I didn't know anything about the configuration steps I became obsolete, especially if you also need to install EPM SDM;