Skip to main content

NAV 2013 & NAV 2013 R2 - How to - Using FlowFilters in OData URIs.

Hi all,

In Previous post related to ODATA we saw how to publish and consume a Odata Web Services from NAV 2013 & 2013 R2.

For Articles Related to ODATA & web services posted before today please Refer Label Web Services.

Today we will see how to Using FlowFilters in OData URIs.



The Example shown below is from NAV 2013 R2 and using a Page web Service. The Steps remain same for Query Web Services and in NAV 2013.

In this procedure, we will create and publish a web service from the Item Card page in Microsoft Dynamics NAV and then query the data in that web service by using a FlowFilter.

How to Publish a Web Service?

The Service Should of Type Page with ID 30 and Web Service Name as MyItems.



Now Let's Check the Metdata of the Created Service (As discussed in earlier Post).

http://<Server>:<WebServicePort>/<ServerInstance>/OData/$metadata

In My Case the URL is -

http://INDEL-SXD6995NB.TecturaCorp.net:6514/PersonalDB/OData/Company('CRONUS%20International%20Ltd.')/MyItems

http://localhost:6514/PersonalDB/OData/$metadata

Below is the ScreenShot of My Page WebService Metadata.



Navigate to End of the Browser Page, you will find that end in the word Filter, as shown below.



Create a URI that returns information for a single item card. For example:

http://localhost:6514/PersonalDB/OData/Company('CRONUS%20International%20Ltd.')/MyItems('1906-S')

And Output is Something Like as shown below. Just Check Value of Qty_on_Sales_Order.



Apply a FlowFilter to that item and specify GREEN as the value for the Location_Filter:

http://localhost:6514/PersonalDB/OData/Company('CRONUS%20International%20Ltd.')/MyItems('1906-S')?$filter=Location_Filter eq 'GREEN'

And Output is Something Like as shown below. Just Check Value of Qty_on_Sales_Order.



For Just for Verification Purpose Let's Check same Item In Navision.



That Completes the task of this post. In Next Post we will see something more about ODATA.

Regards,
Saurav Dhyani
www.sauravdhyani.com

Comments

Popular posts from this blog

Dynamics NAV - All that you need to know about MenuSuites.

Hi Readers, This article is based on a request from a blog reader who wanted to understand about MenuSuite in Dynamics NAV. If you have started working with Business central with AL Code then it does not apply to those releases but if you are interested go ahead. Let's start with Future - In Latest and greatest version of product MenuSuite are obsolete and no longer used. So this article applies if you want to learn about C/AL MenuSuite.

How to Set Up NavUserPassword Authentication in Business Central.

Hi Readers, In this article we will discuss steps to Setup NAVUserPassword in Business Central on-prem. NavUserPassword is an authentication method that's handled by Business Central Server, but isn't based on Windows users or Active Directory. Each user is set up with a username and password that's configured inside Business Central only. The user is prompted for username/password credentials when they start the client. #msdyn365bc, #credentialtype

Microsoft Dynamics NAV 2016 - How to Configure Phone Client.

Hi All, In this article we will discuss how we can connect Microsoft Dynamics NAV 2016 with New Client Launched i.e. Phone Client. This Article Contain Steps for a Android Phone as I have Only Android Phone. I am doing it having all tiers on my windows 8 machine, steps remain same for multiple servers but issues might be different. What we Need (Other what we discuss in this article) -  The Service Tier should be on Public IP . Some of the Data-card does not Provide you Public IP. check it for sure.