You can translate the question and the replies:

Queryable API

For an API, can I query by multiple values? Example, if I have multiple employees, how can I write a queryable API to handpick a few employee's ?employee_id in '02019590, 02019592, 02019593' does not seem to work.
26-09-2019 13:33:51 -0400

1 Answer

Hi, To interact with Rest Webservice, I make use of the various conditions available for input parameters to perform a search and it displays the list of records that matches the search condition. You can pass multiple values for the specified field in a couple of ways. Either you can use the inbuilt search available on the web page or you can add the filter condition in the URL. 1.**Web page search ** In order to pass the multiple values for the specified field, I would perform the below steps * On the web page, click on the ‘search view’ button and select the Input parameters filed. For example, ‘employee_id’. * Select the “iscontained” condition from the drop-down. * Enter the values as ‘02019590, 02019592, 02019593’ and click on the search. * Now I was able to view records based on the condition. 2.**Adding filter condition** You can also use the $filter parameter in the URL.The $filter parameter which filters the rows of a view similar to the where conditions.For example, > http://<Host>:<port>/server/<database>/<web-services>/views/<web-services>?$filter=<filed_name> in (<value1>,<value2>..<valuen>) > Also, for dynamically changing the values in the filter parameter, I would make use of [Interpolation variables]( (like, ?$filter=@variable) and provide the value for this variable during each execution dynamically. For more information, you can refer to the [Input Parameters of the RESTful Web Service ]( section of the Virtual DataPort Administration Guide. Hope this helps.
Denodo Team
27-09-2019 07:31:54 -0400
You must sign in to add an answer. If you do not have an account, you can register here