cancel
Showing results for 
Search instead for 
Did you mean: 

HCP XS trial instance - pass sql parameter via URL

Former Member
0 Kudos

Hello,

I am developing my first application on HANA Cloud Plattform.

I uploaded a table with 13 million rows, but I want that my application just returns a few of them.

Is it possible to pass an parameter via URL to my application?

So that the user can interact with the application and gets only results returned for his input?

Lets say: SELECT * FROM "1084"."Adresses" WHERE  street = ''(and this is the dynamic part, depending on user input).

Could you give me an example of how to best practice the realisation of my concern?

Thanks in advance,

Leon

Accepted Solutions (1)

Accepted Solutions (1)

pfefferf
Active Contributor
0 Kudos

Hello Leon,

is the question here how you can solve it for a specific service (e.g. with XSJS or OData) or is it a more general question what service type you should use.

It will work with XSJS and OData. From a development point of view OData should be preferred here, because all the server-side logic regarding the (standard) filtering options comes out of the box. On the client side, e.g. in a UI5 app you just have to set a corresponding filter for the property. With an XSJS service you have to implement the logic by yourself.

Regards,

Florian

Former Member
0 Kudos

Hi Florian,

can you suggest me a good link for how to solve it with the OData service?

I hope I can access the application (client side) also via a normal HTML5 website, is that true?

Thank you for your time and help,

Leon

pfefferf
Active Contributor
0 Kudos

All XS related things regarding OData on HANA are described here. Of course knowledge about OData itself is necessary. Here is a link to the v2 documentation supported by XS classic: OData Version 2.0

Yes, you can use it in a "normal" (whatever normal means ) HTML5 app, either going the hard way doing the ajax calls by yourself or using one the the available libraries like for instance datajs.

Regards,

Florian

Former Member
0 Kudos

Thank you very much Florian, I will check it out and might get back to you .

Answers (0)