Tag Archives: D365
How To Enable / Disable Maintenance mode Using SQL query in Dynamics 365 for Finance & Operations
In finance and operations for making any changes in License configuration form, you need to enable maintenance mode and after making desirable changes you need to disable to this mode. You can enable or disable maintenance mode using SQL query as well as command prompt. In this blog, we are performing this operation using the SQL query. The following are steps to enabling/disabling maintenance mode:- Open SSMS(Microsoft SQL Server Management Studio) in your server. Click on New Query and enter the following query to enable maintenance mode:- update dbo.SQLSYSTEMVARIABLESset dbo.SQLSYSTEMVARIABLES.VALUE =1 where dbo.SQLSYSTEMVARIABLES.PARM = ‘CONFIGURATIONMODE’ You can verify status using following command:-SELECT * FROM [AxDB].[dbo].[SQLSYSTEMVARIABLES] After this restart IIS services in some cases, you need to restart the server. perform your changes to the License configuration form. after desired changes are made you can disable mode using the following command update dbo.SQLSYSTEMVARIABLESset dbo.SQLSYSTEMVARIABLES.VALUE =0 where dbo.SQLSYSTEMVARIABLES.PARM = ‘CONFIGURATIONMODE’ Now again you can verify status using the same query in step 3 and again repeat step 4.I hope this blog will help you
Move database from sandbox to development in D365 Finance and Operations
Hello, In this blog I am going to demonstrate how to move database from sandbox to development environment. In some cases, there might be a situation where you need to debug the code with production data. For this, first we need to move database from production to sandbox with refresh database in LCS as shown in below screenshot. Then we need to move database from sandbox to development as follows. Steps to move database from Sandbox to Dev Login to LCS and click on Sandbox Environment full details. On Maintain Tab click Move database. To export the Sandbox Database, click on Export Database. 4. You can find the .bacpac file in Database backup of asset library after successfully executing export command . Download the .bacpac file to development VM. 5. Open SSMS in development server. Before importing the database AxDB you must rename the existing AxDB by the following Script. USE master; GO ALTER DATABASE MyTestDatabase SET SINGLE_USER WITH ROLLBACK IMMEDIATE GO ALTER DATABASE MyTestDatabase MODIFY NAME = MyTestDatabaseCopy ; GO ALTER DATABASE MyTestDatabaseCopy SET MULTI_USER GO 6. Right click on Database, select Import Data-tier Application. 7. Click Next. 8. Change the New database name to AxDB and click Next. 9. Click Next and Browse to the folder where .bacpac is downloaded. 10. Click Finish to import database. 11. You can see the Steps as follows. 12. Once Import is done, Open Visual Studio and do Full Synchronization. I hope this blog will help you.
How to create and apply workflow for purchase order in D365 finance and operations
In this blog we will learn how to create workflows in D365 finance and operation. For this blog we are taking example of Purchase order workflow. Which will allow us to create purchase order which is allocated to different persons for approval and review process. Navigate to Procurement and Sourcing >>Setup>>Procurement and Sourcing workflows, and click on new and select purchase order workflow as follows:- This will open workflow editor in you first need to provide log in details same as that of environment. Here we need to arrange various components and need to set their properties to resolve those following errors. Components for this of workflow: – Start: – To indicate start of workflow design. End:- To indicate end of workflow design. Review Purchase order:-This assign review(Complete/Return PO). Approve Purchase order:- This assign users who needs to approve purchase order. To design workflow follow the steps :- Now In designer create design as shown in screenshot Set the Review element and right click and open properties and set as basic settings as follows:- In assignment make sure you have assigned type(in our case user) and user name You can also escalate roles after certain time as follows(we are not considering this setup for this blog) Now get back to approve purchase order and open its properties for and set automatic action as follows which will approve Purchase order below 10000 USD. Set the notification for person who will receive notification when particular operation is performed(for eg :- Approved/rejected etc) Now click on step 1 to enter in step 1 section and open its properties. First we are assigning user who will approve the purchase order as screenshot suggest as well as you can set time limit for approval and completion policy as well. You can also add the condition to step 1 which will decide whether to run this step or notNow close step and get back to main design of designer Now click on save and close and mention version notes and activate this workflow Now you can see new workflow in procurement and sourcing workflows Now create new purchase order and after that click on workflow button and click on submit you can also check history of it Now another user will complete the purchase order approval and mention comment. Now user with authority of approval will approve from common>>Work Items assigned to me
Model import and export in D365 Finance and Operations using Powershell
When we want to move customization done on specific model from one environment to other development environment we need to export and import the model file. Steps for model import and export using PowerShell :- Open PowerShell in administrator mode. Change directory to the path of package bin folder. Export command:-.\ModelUtil.exe -export -metadatastorepath=C:\AOSService\PackagesLocalDirectory -modelname=”name of model” -outputpath=path to store model after exportFor example: If model name is TOUpgradeModel and I want to store the model file to path is C:\Temp\ModelFile The command will be as follows: .\ModelUtil.exe -export -metadatastorepath=K:\AosService\PackagesLocalDirectory -modelname=”TOUpgradeModel” -outputpath=C:\Temp\ModelFile Output file you can see on the specified path as Import Command :-.\ModelUtil.exe -import -metadatastorepath=C:\AOSService\PackagesLocalDirectory -file=the path from. axmodel to importFor example: .\ModelUtil.exe -import -metadatastorepath=C:\AOSService\PackagesLocalDirectory -file=C:\Temp\ModelFile\TOUpgradeModel-Cloudfront.axmodel ( Note : If model already exist in your environment, trying to import the same model you will receive the error message of “Model already exist”. So, delete the existing model by command .\ModelUtil.exe -delete -metadatastorepath=C:\AOSService\PackagesLocalDirectory -modelname=” TOUpgradeModel ” try to import the model)
How to resolve Error “Exception from HRESULT: 0xC0202009” While data export
While Exporting data using data entity in D365 FO sometimes the Data project fails to export data with error “Exception from HRESULT: 0xC0202009”. While event log displays – EventData methodName DMFGenerateSSISPackage.generateFileDataV2() diagnosticsMessage System.Exception: Exception from HRESULT: 0xC0202009 at Microsoft.Dynamics.AX.Framework.Tools.DMF.ServiceProxy.DmfEntitySharedTypesProxy.DoWork[T](Func`1 work) at Dynamics.AX.Application.DMFGenerateSSISPackage.`generateFileDataV2(DMFDefinitionGroupExecution _dmfDefinitionGroupExecution, String _defGroupName, DMFFileFormat _fileFormat, DMFDelimiter _rowDelimiter, DMFDelimiter _columnDelimiter, String _codePage, String _locale, NoYes _isFirstRowHeader, NoYes _unicode, String _source, String _textQualifier, DMFXMLStyle _style, String _rootElement, String _filePath, Map _entitySyncVersion, Int32 _previewCount, Boolean @_entitySyncVersion_IsDefaultSet, Boolean @_previewCount_IsDefaultSet) in xppSource://Source/ApplicationFoundation\AxClass_DMFGenerateSSISPackage.xpp:line 1273 In Such Cases, the reason behind this is some target fields is may be disabled or cause this problem. To resolve this problem, you need to perform the following steps :- Refresh Entity List Data Management>>Framework parameters>>Entity Setting And wait until all entities got refreshed Regenerate Mapping – Select data entity with the above issue (In our case Sales Order header v2 Entity)from data entities in data management. Click on Generate Mapping – Select “Yes” from generation warning Note:-You can try to disable/remove fields from the mapping until it starts working. This way you at least find out the problematic field. To be more effective, disable the first half of the field list. If the export works, the problem was in some of the disabled fields. I hope this will help you.
Error “A reference to ‘xyz ‘ is required to compile this module” solution
Many of the time while building project/solution we came across the “reference is required to compile this module error”. The reason behind this error is that your module’s reference package is missing the required package. In error itself, the missing module can be rectified as shown for example in following screenshot reference to “SourceDocumentationTypes” is not made. Now you have to add a missing reference to your module as follows: Select Update model Parameters from Dynamics 365 >>Model Management>>Update model Parameter Now select the required model name from the model list and click on Next. Now make sure to select the checkbox in front of a required reference from reference packages (In our case SourceDocumentationTypes reference was not there ) and click on next. Now click on finish. Now after attaching a reference to the package build package/Solution and you have solved your error.
Dynamics 365 Finance and Operations : Picking and Receiving – Transfer In Process in Retail POS
Steps to Perform Transfer In in Dynamics 365 for Retail on POS Go to Picking and Receiving –> click on + icon and click Transfer In Select the store from where you want to transfer in, Delivery date and mode of delivery. Add or scan all the products and its quantity. Click on + icon to add more products to the transfer order You can save the products added by clicking on Save icon. The status of the order will be in Draft. You can continue adding products when it is in Draft state by clicking on + icon. Once you are done adding all the products click on commit icon. Once the order is committed the status will change to created and you will not be able to add products. Once the Order is created, the Order will reflect in the store from where the order is requested. Perform the following steps in that store. For example the warehouse. [Products can be shipped from Finance and Operations as well] Select the transfer In order and click the update icon. Click on ship all icon to ship the products. This will change the ship now column with values to ship. Then click on commit. This will change the status of the order to shipped. When the status is changed to shipped the same status will reflect in the store 101 as well. On store 101 User must click on the transfer order and click on update. Click on receive all icon and click on commit icon. This will complete the process.
HTTP POST Requests using Microsoft Flows
Introduction: In this blog we will demonstrate the working of HTTP Request -Response in Microsoft Flows. Implementation: Step 1: In our example we will make a POST call to our Microsoft Flow so that we can further apply some logic in Flows. The POST request contains the following data. JSON: [{ “name”: “TestName”, “Address”: “TestAddress” }] Now we can use online editor tools to create a schema file of the above JSON. (https://jsonschema.net/). Submit the JSON data and the schema will be generated as shown below. Step 2: Now we go to Microsoft Flows,create a new flow and add the first step as “Request” as shown below: Step 3: We then paste the JSON schema that we earlier saved In the “Show advanced” options we have to add the following details: Once that is done we select a condition. In our example we will pass a JSON Array hence we will loop through each item. Here we add a apply to each condition as shown And we add a dynamic output from the previous stage Then inside the apply to each loop we can add any action and take the values passed from the POST request. For this example I create a new account in CRM with the name and address provided as shown below Step 4: Now when we save this flow a URL is generated in the First HTTP Request step. We test the flow by calling this URL from Postman. The URL generated is show below Step 5: Now we open Postman and write the request as shown below Also in the Header section we add the following details Step 6: Once we click on Send the two records are created in CRM as shown below Conclusion: We can call this URL from outside Dynamics CRM as well and using this we explore many more functionalities provided by Microsoft Flows to achieve the desired outcome.
Store Coupon Code in Dynamics 365 Finance and Operations
Introduction: In this blog we will see how to apply coupon discount on MPOS (Store) in Dynamics 365 for Finance and Operations. Steps: Step 1: Create Bar code Mask Character for Coupon Code. Step 2: Create a New Barcode Mask set up. Keep the type as Coupon. Step 3: Create Bar Code for Coupon. Assign the Mask ID which was created in step 2. Step 4: Create Number Sequence for Coupon Code ID and Coupon Number. Step 5: Set the Retail Parameters for Coupon. Assign the Mask ID that was created. Step 6: Create a New Discount. Mention the discount Price, Products in Lines, Price group, Valid Discount Account and enable coupon code required. Step 7: Create a new Coupon. Mention the usage limit, usage type, associate discount to the coupon, Create a new line for coupon. Activate the Coupon. The Bar code will be generated. Make a note of the Bar code. This is how you set up Coupon Code on Stores in Dynamics 365 for Finance and Operations. Run Jobs and flow the discount to the store. To Redeem the Store Coupon Code: Step1: Scan the product that is under Discount. Step2: Scan the Barcode or Manually inter the Barcode. Step 3: The discount will be applied to the product along with the discount name Step4: Make Payment.
Pin Embedded Power BI Reports to Workspace in Dynamics 365 for Finance and Operations
Introduction: In this blog article, we shall see how to pin the power BI reports to Workspace. How to pin? Power BI reports can be added to any workspace that contains a Links section. Once the Power BI reports have been deployed successfully you can pin them to your Dynamics 365 Finance and Operations Workspace. Steps: Open a workspace in Dynamics 365 For Finance and Operations In the workspace, click the Options tab Click Open Report Catelog The list of reports comes from the reports that you have in your Power BI account Click on Ok and those reports will be on your workspace Similarly any customized or out of the box reports can be pinned to your workspace.