In our previous articles related to Inventory Visibility Service, we have covered how it serves as the solution to manage business inventory, as well as explored how to use Dynamics 365 SCM as an example of a process to transfer data from an ERP system to a microservice.
Oftentimes, the inventory data lies in multiple systems or sources, and even Inventory Visibility Service resolves this problem by providing a single source of truth, concatenating data from different sources. In this article, we would like to shed more light on the process of configuring updates and query Inventory Visibility Services to handle changes from multiple systems.
Example Scenario
We would like to touch base on a specific scenario to operate the franchise stores with Inventory Visibility to update inventory counting and near real-time stock deduction upon sold quantities. This is a simplified scenario where we have dynamics SCM (as an ERM system), an external ERP system, and the final system record for the transactions. There is also the Point of Sales System (POS) as an external system and the Inventory Visibility microservice.
The store sells sandwiches in the original stock of 100, and this is synchronized into Inventory Visibility (IV) during the default integration. From the external system, if a customer places an order through the app and in the pick-up store, an inventory availability query can be made into IV only within the order placement screen.
Once availability is confirmed and an order is placed to the point of sale system (for example, a sales order of 10 sandwiches), the store then posts the detection IV either instantly or periodically. Our customer also wants to track not only the consumption of finished products but other info like milk and sugar consumption per beverage as well.
Therefore, their inventory adjustment requests will first hit a customized middle tier which will do exploration, and then the consumption of finished products together with individual materials are posted into IV. With this step, you can already obtain and rely on IV to support business ops.
Of course, this is custom, and typically for most customers, they are not in a rush to update ERP stock levels because they already guess that the near real-time inventory update is in IV already.
In that case, they can actually synchronize the orders or inventory changes, either aggregated or in bulk, later to the ERP system (let`s say to Dynamics SCM for further ordering, processing, and physical inventory update). With the update and other inventory changes in Dynamics 365 SCM, such as new goods, receipt quantities are also synced back into IV (IV – Inventory Visibility).
And, there is a way that IV can make sure the ERP IV sync does not double deduct the same inventory twice while the offset. This solution is currently customizable, but the MS team is to be said to be working on an out-of-box product release to be available publicly.
Another use case for inventory adjustment is inventory counting. You can directly post your inventory counting results to Inventory Visibility and offset later when you post the inventory counting journal in Dynamics 365 SCM.
Lastly, you can always query Inventory Visibility from your other data sources if needed.
Potential Challenges without IV-3rd Party Connections
There are a few potential challenges that may occur if you are using Inventory Visibility and operating across multiple systems but not connecting 3rd party systems with Inventory Visibility.
Taking the fictional company Contoso Entertainment System USA as an example, Contoso has already connected Dynamics 365 with Inventory Visibility Service, but not yet their retail store point-of-sale (POS) systems.
Then, retail stores have a POS system from 3rd party vendor, currently loosely coupled with Dynamics 365 SCM and with transactions not being updated in Dynamics 365 in time. When the stores do inventory counting, the new inventory quantities are not yet reflected instantly in Dynamics nor in Inventory Visibility yet.
Sequentially, if Contoso expands fast, it will take lots of effort to harmonize new stores` data to Dynamics 365. Plus, the inventory query response from Dynamics 365 will take lot of time.
Lastly, since Contoso also operates online channels and across mobile apps, they will not have visibility into actual stock levels through those channels either.
Inventory Visibility Service Configuration
We begin with the step when Inventory Visibility is already integrated with Dynamics 365 Supply Chain Management, and our starting point is when Visibility Service has nothing more than being connected to Dynamics. Meaning we start from a totally blank configuration.
Dynamics 365 SCM – IV – POS Data Flow
Let’s first illustrate what a typical day is like for a retail user of Inventory Visibility Service in the Contoso entertainment system company.
The solution will consist of three parts:
- Dynamics 365 SCM as the back-end ERP system;
- Inventory Visibility;
- 3rd POS System.
At the beginning of the day, Dynamics 365 Supply Chain Management synchronizes on-hand data to Inventory Visibility Service. During normal business hours, the POS system would have a lot of orders to process queries, as syncing other queries to Dynamics is a very heavy workload.
To a typical ERP system, we decide to sync such data to Inventory Visibility directly, which makes the IV the only source of truth during business hours. And, there are advantages to this approach:
- Firstly, we leverage the performance of the Inventory Visibility Service as well as the potential extension possibilities provided by the Power Platform.
- Secondly, during business hours, even trade managers without access to the Dynamics POS system can make queries to Inventory Visibility Service with API calls.
To save the load of the ERP system’s back-end, we can sync the data in batches back to Dynamics 365. Such a solution is feasible and extendable even with more systems incurred by putting Inventory Visibility Service in the center as the single source of truth.
Data Sync Process
At the beginning of the day, Dynamics 365 syncs the data to Inventory Visibility Service with the available physical quantity of 100. At this point, there are no quantities being sold from the POS system. Therefore, the POS system should have 100 available to be sold.
In the morning, let’s say 10 am, the POS system may have 10 orders with 20 sold pieces in total. We are required to tell Inventory Visibility Service that the POS system has sold 20 pieces. And Inventory Visibility Service would calculate that there are 80 pieces available to be sold.
A similar story happened in the afternoon when the store sold five more pieces, and there were 75 left. In the evening, after the store is closed, the POS system does two things. Firstly, it syncs the data back to Dynamics 365 SCM so that it knows that there are only 75 pieces remaining by updating the order status correspondingly. Secondly, the POS system is in charge of resetting the data from the POS sold quantity in Inventory Visibility Service – so that Inventory Visibility Service would know there are 75 pieces remaining to be sold.
And at the begging of the second day, Dynamics will make a replacement and replenishment of 25 pieces to begin with a hundred again.
Inventory Visibility Service Configurations
Data Source
To achieve the process that has been described above, we need to go through the Inventory Visibility Service Configuration. Firstly, to indicate that the data comes from a different source, we have the concept of data source and name it POS.
The Data Source contains a name as well as two important aspects. Firstly, the physical measure, which is an input quantity field (i.e., sold quantity). Secondly, it’s dimension mapping. In case the input data contains a different dimension name that is within the base dimensions provided by Inventory Visibility Service, we need to set up a mapping that maps different input dimensions to the same base dimension. This way, we will know two data sources are modifying the same record.
Index Hierarchy for Performance Optimization
After we had configured the data source, it is optional to set up an index hierarchy for performance optimization. An index hierarchy tells Inventory Visibility Service to store the data in a performance-optimized way. For example, if all the items in the Contoso company contain the size dimensions, they may want to add size to the hierarchy to enhance the query performance, grouping by sides.
Setup Calculated Measures
Lastly, we want to set up calculated measures, defining the arithmetic results into one value. For instance, we want to store a value in POS available, which indicates the difference between the available physical transfer from Dynamic 365 Supply Chain Management from the beginning of a day and the total quantities being sold during business hours.