Skip to Content
0
May 22, 2014 at 04:35 PM

UI 5 and XSJS

159 Views


Hi HANA Experts,

I was trying to build a application where:

1) Users will enter a state

2) And application will return the list of customer in that state

I created a UI5 Application project in HANA Studio. Got the "index.html", the view and it's associated controller files. I then tried to call the data-base using the xsjs calls inside the controller. Like $.db.getConnection() etc. The file got activated. However, it started giving errors when I tried to run from the browser. And I saw that system is unable to find ANY OF THE "$" FUNCTIONS OF XSJS. I saw that the XSJS library files are missing from the Project. So I manually added it to the UI5 application Project. But the error existed.

My question is:

1) How to call "$.db.getConnection()" and other "$" functions from the UI5 application projects?

2) What's the technical difference between "XSJS" proejct and "UI5 Application" project?

3) When to use each of these Project types?

4) I now went ahead and created a "XSJS" project in HANA studio. The "$.db" functions started working. However the UI5 application libraries went missing. Does this mean UI5 is not compatible with "XSJS" services

5) If you can share me a sample code of using UI5 and XSJS, would be a good help

Your answers will be very much appretiated.

Regards,

Kowshik