Skip to Content
Technical Articles
Author's profile photo Sreekanth Surampally

Common Errors and Fix – XSA Web IDE for HANA developments

When I started building objects in Web IDE for HANA on XS Advanced server, there are quite a few number of errors during build or deployment of the objects in HANA. I found answers to those errors in SAP Community forums and that was very helpful. Then I thought of consolidating those common errors and the resolutions at one place in this technical document.

Error #1: When trying to build any object in the MTA project, failed with an error, No Space is defined for the project.

Root Cause and Fix: MTA project developments need a space to store the objects in database, so an organization’s space of XS Advanced must be assigned to MTA project. This can be done, project settings menu — > Select the required space from the available list.

Note: Do not select SAP space, because it is used for standard XS applications and services. Choose the one created by you, for example “Dev”.

Error #2: When I am trying to assign a space to a project, get an error “Could not retrieve a list of spaces” as shown in the below picture.

Root Cause and Fix: It is because user SSURAMPALLY is not added as a member in that space. Go to XS advanced cockpit, select the space and then add members and provide the user name SSURAMPALLY.

Error #3: When I am trying to build a database module object, process failed with an error “Object has to be prefixed with name space”.

In this example, I create a column table “Employee” as .hdbtable object in a DB module, when tried to build it, failed with the below error shown in the Picture.

Root Cause and Fix:  Build failed due to the configuration in .hdinamespace file, it has a name which is made of Project and DB module names. So with that, any design time object must be prefixed with this name. Usually name space is required to uniquely represent the object if there is a possibility that there could be multiple objects with same name in different folders or modules.

Fix1 : Column table name will be prefixed with the name space as shown in the below picture.

Fix2: You can also delete the name space file completely, if you feel that there is no possibility of having duplicate names in the project, in this case no name space prefix required and the  build will not fail. I usually prefer this option, delete the .hdinamespace file when I start working on a MTA project.

Fix3: update the .hdinamespace file,  update the subfolder with “ignore” instead of “append”.,  name parameter with empty string.

Error #4: When trying to build a DB module object, failed with an error “Data version only supports build plug in Version 2.0.xx or lower”, as shown in the below picture.

Root Cause and fix: While Creating the DB module, database version is chosen as HANA 2.0 SP 4, however my current DB version is HANA 2.0 SP 3, So build failed with an error due to build plug in support. The plug in version can be seen in .hdiconfig file as shown in the below picture.

Fix: update the plug in version with 2.0.33 or lower, so that it does not get any compatibility issue. XSA is backward compatible, so you can go as lower as 1.0.11 also.

Error #5: When I am trying to build a calculation view, failed with an error, “the file requires xxxx which is not provided by any file.

In this case, I am creating a simple calculation view using 2 DB tables, EMPLOYEE and EMPLOYEE_SALARY.  EMPLOYEE table is created as design time object, in Database DB module, EMPLOYEE_SALARY table is created directly in the DB explorer as run time object using SQL console. Therefore, build of the calculation view failed with the error shown in below picture.

Root Cause and Fix: EMPLOYEE_SALARY table exists as DB table in the system, but it is not part of design time object of the MTA project and DB module. So that, build of calculation view is happening in design time and it requires the EMPLOYEE_SALARY table definition as the design time object.

So Create the EMPLOYEE_SALARY table as .hdbtable in Database module of MTA, then try to build the CV, it should be successful.

Error #6: When I try to build the .hdbgrants file in a DB module which has custom user provided service to connect to Classic Schema, failed with error ‘Service not found’ as shown in below picture.

Root cause and Fix: Custom user provided service to access external objects has been created with name cross-schema-service, it has SERVICE_REPLACEMENTS configuration in mta.yaml file to get the service name dynamically based on environment.

So I will have to use either the hardcoded service name or key in the SERVICE_REPLACEMENTS as highlighted in the above picture.

Error #7: Mixing up the Tenants for Object creation and Custom user provided service creation.

When I try to build the db module failed with error in .hdbgrants file about Invalid user name #OO and error in .hdbgrants file as shown in below picture.

Root cause and Fix: Database module objects are mapped to a space and then further they are getting deployed to one of the tenants, sometimes, if you properly did not configure in tenant and space mapping correctly, it goes to SYSTEM DB. On the other side, Customer provided service is created on HXE tenant DB, as an external connection established. 

So with that, when you trying to access HXE tenant objects for the objects in SYSTEM DB, .hddbgrants can’t be successful. So we will make to sure to use correct tenant for CUPS and the current db module developments.

Note: if you have more tenants, make sure you give the right PORT number to connect to that tenant.

Error #8: Build of the DB module failed with error, unable to grant the access on DB role to #OO user or Calculation view can’t display data out.

In this case, I have shown a calculation view which has synonym that is created on a target table which is available in Classic database., there is a DB role which provides the access to that target table, the service creation user (SSURAMPALLY) has already got the access to that schema. When the data display on the calculation view gives an error message as shown below. Or you could notice that, build failed with unable to grant access on role to #OO users.

Root Cause and Fix:  The DB access role created in classic Database is not enabled to have Grantable to others, so with that schema access on classic DB did not get passed to Container object owner #OO.  So you must select the Grantable to other users option as shown in below picture.

Error #9: Accessing a DB table of HDI container in Classic Database failed with authorization error.

Root Cause and Fix: By default, HDI container objects are isolated and can’t be directly accessed in classic database. In order to provide the access, following procedure must be run in Admin console of HDI container in DB Explorer.

Error #10: Building a MTA project, giving the message that .mtar file has been generated instead of build completed successfully.

Root Cause: Selecting the MTA project and Choose Build is not a regular activation of objects in different modules of MTA. It makes an .mtar file generation which is for cleaner deployment. In other case, when individuals modules build is a private build and only specific to developer container. So make sure, you have built all the modules in MTA before you generate Archive file. This archive file can be used by other developers and make further changes to continue development.

Summary: In this document, I covered the basic errors when you started with Web IDE for HANA developments, also covered some of the access related errors to understand. In the next document, I will cover few deployment related errors and fix.

Thank you. if you have any comments, please share, I will update the content accordingly.

Assigned Tags

      7 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo bysani balaji
      bysani balaji

      Hi Sreekanth,

      Thanks for sharing useful docuement, I am facing Error #2, Will perform the steps which you suggested.

      Author's profile photo Eronita Scott
      Eronita Scott

      Useful Information, your blog is sharing unique information….
      Thanks for sharing!!!

      Author's profile photo Ahmed Ali Khan
      Ahmed Ali Khan

      Highly appreciated your efforts, Awesome document.

      Can you also tell me, Even though i im the first owner of a schema my XSA is creating the schema with SCHEMA_1.

      Default what i know is if you create any schema in the system with XSA it will create your artifacts with the same schema and if other developer build the same module it works as schema_1.

       

      Does it looks like a bug?

      Author's profile photo Sreekanth Surampally
      Sreekanth Surampally
      Blog Post Author

      Hi Ahmed, it is not a bug. In the latest releases of Web IDE for HANA MTA template,SAP made that in a way it starts with schema name to look better to first developer, then the next developer will get schema_name_1 and so on. In other releases, first developer starts getting schema_name_1. But what ever the release you get, you can always control this behavior with parameter "make unique name"

      https://blogs.sap.com/2019/05/17/sap-web-ide-workspace-and-hdi-container-isolation-or-how-to-work-on-one-schema-with-multiple-developers/

      Author's profile photo BDA-BICC Team
      BDA-BICC Team

      Hi Sreekanth,

      Data preview is not working example if we right click on any calculation view and select data preview it will open I/P or Variables we have for that Calc view after entering the mandatory fields then we will select "open content" it is just like play button. when i click that button I am not able to see the data preview but when I click the button next it which "Open SQL Console " from their I am able to see the data. But problem here is I am unable to do quick analysis every time I have go the Console and check for data we have less options in console compare to normal data preview , could you please suggest

      Author's profile photo Adam Cox
      Adam Cox

      Hi. Thanks for this contribution. I am using SAP HANA XS Advanced WebIDE, and I find issue when moving files around in my Web module. Seems files do not get copied or referencing paths are not satisfactory to locate. For example:

      app.js:

      import { stuffListComponent } './src/components/stuff/stuff-list-component-vue.js'


      some-list-component.js:

      var stuffListComponent = Vue.component('stuff-list', { ... }

      export { stuffListComponent }


      File arrangement:

      - /src/components/stuff

      - stuff-list-component-vue.js

      - /src/app.js

       

      Author's profile photo Kiran Subramaniam
      Kiran Subramaniam

      Hi Sreekanth,

      I have one XSA application which works fine with "redirect-uris" of deployed version, however when built locally and even after adding local build application url into "redirect-uris" of Oauth section in xs-security.json , the app is throwing the below error message:  "Invalid redirect https://....login/callback did not match one of the registered values".

      Can you please suggest how to resolve this local build issue ?