Monsieur Winner https://blog.monsieurwinner.com/ MS D365FO || Monsieur D365FO Sun, 13 Oct 2024 23:39:23 +0000 en-US hourly 1 https://wordpress.org/?v=6.6.2 https://i0.wp.com/blog.monsieurwinner.com/wp-content/uploads/2022/09/cropped-Winner-.png?fit=32%2C32&ssl=1 Monsieur Winner https://blog.monsieurwinner.com/ 32 32 209261758 The group Dynamics365ReadServices is not present in the ACL of the service SqlServerReportingServices. https://blog.monsieurwinner.com/2024/10/13/the-group-dynamics365readservices-is-not-present-in-the-acl-of-the-service-sqlserverreportingservices/ https://blog.monsieurwinner.com/2024/10/13/the-group-dynamics365readservices-is-not-present-in-the-acl-of-the-service-sqlserverreportingservices/#respond Sun, 13 Oct 2024 23:39:23 +0000 https://blog.monsieurwinner.com/?p=758 While deploying an LBD (Local business data) commonly called D365 Finance and Operations on-premises, the Test config on the BI(SSRS)

The post The group Dynamics365ReadServices is not present in the ACL of the service SqlServerReportingServices. appeared first on Monsieur Winner.

]]>
While deploying an LBD (Local business data) commonly called D365 Finance and Operations on-premises, the Test config on the BI(SSRS) node gave the error.

The group Dynamics365ReadServices is not present in the ACL of the service SqlServerReportingServices.

 

Below the steps used in resolving it.

  1. Go to your BI node.
  2. Open lusrmgr.msc (Local Users and Groups).
  3. Create a new group called Dynamics365ReadServices.
  4. Add the account that your AOS runs under (such as axserviceuser, svc-AXSF$) to the group you created above.
  5. Download the latest infrastructure scripts from the Shared asset library in Lifecycle Services.
  6. Copy the infrastructure scripts to your BI (SSRS) node.
  7. Create a file scmgroups.csv with the following content.                                                                                                                                                                    “Name”                                                                                                                                                                                                                  “Dynamics365ReadServices”
  8. Run the following command in PowerShell with Administrator privileges.
    .\Set-ServiceControlManagerPermissions.ps1
  9. Run the following command in PowerShell with Administrator privileges to verify the setup.
    .\Set-ServiceControlManagerPermissions.ps1 -Test

 

 

The post The group Dynamics365ReadServices is not present in the ACL of the service SqlServerReportingServices. appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/10/13/the-group-dynamics365readservices-is-not-present-in-the-acl-of-the-service-sqlserverreportingservices/feed/ 0 758
Deploy SSRS report via powershell script – D365 Finance and Operations on premises https://blog.monsieurwinner.com/2024/10/13/deploy-ssrs-report-via-powershell-script-d365-finance-and-operations-on-premises/ https://blog.monsieurwinner.com/2024/10/13/deploy-ssrs-report-via-powershell-script-d365-finance-and-operations-on-premises/#respond Sun, 13 Oct 2024 09:55:24 +0000 https://blog.monsieurwinner.com/?p=753 While deploying a UAT or PROD environment from LCS for an On premises environment, series of scripts are ran and

The post Deploy SSRS report via powershell script – D365 Finance and Operations on premises appeared first on Monsieur Winner.

]]>
While deploying a UAT or PROD environment from LCS for an On premises environment, series of scripts are ran and executed to deploy different applications:  Common, reportinfservices, aos, financialreporting.

When the deployment fails, we should first of all check the service fabric explorer to identify the application where the failure happened.

This tells us the exact node of the cluster to further access for meaningful info.

In my case, the version of reporting services (2022 build 16.0.1116.12) used in deploying FinOps 10.0.40 did not work. I used a lower version 16.0.1115.61 .
After re-installation of the reportingservices, to manually deploy the report run the following script on the SSRS VM.
.\DeployAllReportsToSsrs.ps1 -PackageInstallLocation \\XXXAOSTEST1\C$\ProgramData\SF\XXXOSTEST1\Fabric\work\Applications\AXSFType_App9\AXSF.Code.1.0.20240725\Packages

 

The post Deploy SSRS report via powershell script – D365 Finance and Operations on premises appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/10/13/deploy-ssrs-report-via-powershell-script-d365-finance-and-operations-on-premises/feed/ 0 753
Cannot connect to Dataverse with Power Platform Tools for VS 2022 https://blog.monsieurwinner.com/2024/09/25/cannot-connect-to-dataverse-with-power-platform-tools-for-vs-2022/ https://blog.monsieurwinner.com/2024/09/25/cannot-connect-to-dataverse-with-power-platform-tools-for-vs-2022/#respond Wed, 25 Sep 2024 14:20:43 +0000 https://blog.monsieurwinner.com/?p=744 With the advent of PPAC (Power platform admin center), part of the setup your Visual studio for development is to

The post Cannot connect to Dataverse with Power Platform Tools for VS 2022 appeared first on Monsieur Winner.

]]>
With the advent of PPAC (Power platform admin center), part of the setup your Visual studio for development is to connect it with a Dataverse.

You might get the error   {“error”:”interaction_required”,”error_description”:”AADSTS50076: Due to a configuration change made by your administrator, or because you moved to a new location, you must use multi-factor authentication to access ‘00000007-0000-0000-c000-000000000000.

This is due to authenticator policy of the organization you are using for the connection. You might want to disable the security default.

 

The post Cannot connect to Dataverse with Power Platform Tools for VS 2022 appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/09/25/cannot-connect-to-dataverse-with-power-platform-tools-for-vs-2022/feed/ 0 744
Copy database from D365FO On premises to Cloud hosted environment https://blog.monsieurwinner.com/2024/09/15/copy-sql-database-from-d365fo-on-prem-to-cloud-hosted-environment/ https://blog.monsieurwinner.com/2024/09/15/copy-sql-database-from-d365fo-on-prem-to-cloud-hosted-environment/#respond Sun, 15 Sep 2024 07:46:00 +0000 https://blog.monsieurwinner.com/?p=740 We can move database from On premises environment to a cloud hosted environment for testing purposes. This process is quite

The post Copy database from D365FO On premises to Cloud hosted environment appeared first on Monsieur Winner.

]]>
We can move database from On premises environment to a cloud hosted environment for testing purposes. This process is quite seamless as both environment are SQL severs. Hence, we backup from A and restore on B.

 

A. Take a back up of AXDB on the On-premises environment

B. Restore the database on the Cloud hosted environment(CHE).

C. Run some sql script against the CHE to update certain values.

D. Synchronize the CHE database.

 

I would skip the steps A and B and move straight to the scripts.

Step 1

USE AXDBonprem;
SELECT s.name
FROM sys.schemas s
WHERE s.principal_id = USER_ID('axdbadmin');

Step 2


ALTER AUTHORIZATION ON SCHEMA::db_owner TO dbo;
ALTER AUTHORIZATION ON SCHEMA::db_ddladmin TO dbo;
ALTER AUTHORIZATION ON SCHEMA::db_datareader TO dbo;
ALTER AUTHORIZATION ON SCHEMA::db_datawriter TO dbo;

step3

USE AXDBonprem;
declare
@userSQL varchar(1000)
set quoted_identifier off
declare userCursor CURSOR for
select 'DROP USER [' + name +']'
from sys.sysusers
where issqlrole = 0 and hasdbaccess = 1 and name != 'dbo' and name != 'NT AUTHORITY\NETWORK SERVICE'
OPEN userCursor
FETCH userCursor into @userSQL
WHILE @@Fetch_Status = 0
BEGIN
exec(@userSQL)
FETCH userCursor into @userSQL
END
CLOSE userCursor
DEALLOCATE userCursor

step4

–now recreate the users copying from the existing database:
use AXDB –******************* SET THE OLD TIER 1 DATABASE NAME****************************

go
IF object_id('tempdb..#UsersToCreate') is not null
DROP TABLE #UsersToCreate
go
select 'CREATE USER [' + name + '] FROM LOGIN [' + name + '] EXEC sp_addrolemember "db_owner", "' + name + '"' as sqlcommand
into #UsersToCreate
from sys.sysusers
where issqlrole = 0 and hasdbaccess = 1 and name != 'dbo' and name != 'NT AUTHORITY\NETWORK SERVICE'

step 5


go
use AXDBonprem --******************* SET THE NEWLY RESTORED DATABASE NAME****************************
go
declare
@userSQL varchar(1000)
set quoted_identifier off
declare userCursor CURSOR for
select sqlcommand from #UsersToCreate
OPEN userCursor
FETCH userCursor into @userSQL
WHILE @@Fetch_Status = 0
BEGIN
exec(@userSQL)
FETCH userCursor into @userSQL
END
CLOSE userCursor
DEALLOCATE userCursor

STEP 6
COPY ADMIN USER

use AXDBonprem
--Update the Admin user record, so that I can log in again
UPDATE USERINFO
SET SID = x.SID, NETWORKDOMAIN = x.NETWORKDOMAIN, NETWORKALIAS = x.NETWORKALIAS,
IDENTITYPROVIDER = x.IDENTITYPROVIDER
FROM AXDB..USERINFO x --******************* SET THE OLD TIER 1 DATABASE NAME****************************
WHERE x.ID = 'Admin' and USERINFO.ID = 'Admin'

STEP 7

Now, let’s rename the orginal AXDB to AXDB_old

USE master
GO
ALTER DATABASE AxDB
SET SINGLE_USER
WITH ROLLBACK IMMEDIATE
GO
ALTER DATABASE AxDB
Modify Name = AxDBold
GO
ALTER DATABASE AxDBold
SET MULTI_USER
GO

Step 8

Rename AXDBonprem to AXDB


USE master
GO
ALTER DATABASE AxDBonprem
SET SINGLE_USER
WITH ROLLBACK IMMEDIATE
GO
ALTER DATABASE AxDBonprem
Modify Name = AxDB
GO
ALTER DATABASE AxDB
SET MULTI_USER
GO

 

The post Copy database from D365FO On premises to Cloud hosted environment appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/09/15/copy-sql-database-from-d365fo-on-prem-to-cloud-hosted-environment/feed/ 0 740
Missing TFVC Option in Azure DevOps: Creating a New Project https://blog.monsieurwinner.com/2024/08/07/missing-tfvc-option-in-azure-devops-creating-a-new-project/ https://blog.monsieurwinner.com/2024/08/07/missing-tfvc-option-in-azure-devops-creating-a-new-project/#respond Wed, 07 Aug 2024 18:52:43 +0000 https://blog.monsieurwinner.com/?p=733 It’s August 2024, and I am trying to create a create a new Azure DevOps project for a new Dynamics

The post Missing TFVC Option in Azure DevOps: Creating a New Project appeared first on Monsieur Winner.

]]>
It’s August 2024, and I am trying to create a create a new Azure DevOps project for a new Dynamics 365 Finance implementation project. It turns out TFVC is not available anymore as a version control. This is coming after Microsoft published  Git walkthrough for D365 Finance & Supply chain implementation.

Hence , create a new Azure DevOps project would have you choose Git as default version control and TFVC is totaly missing.. This tell us we need to start using this for future project and obviously migrate current D365FO repositories from TFVC to Git.

If you probably are not ready to start using Git, fear not :). At least for now, you can enable the TFVC option form the organization’s setting.

You should have it turned off as shown above.

 

Missing TFVC Option in Azure DevOps

The post Missing TFVC Option in Azure DevOps: Creating a New Project appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/08/07/missing-tfvc-option-in-azure-devops-creating-a-new-project/feed/ 0 733
How to convert from date to string using x++ https://blog.monsieurwinner.com/2024/08/06/how-to-convert-from-date-to-string-using-x/ https://blog.monsieurwinner.com/2024/08/06/how-to-convert-from-date-to-string-using-x/#respond Tue, 06 Aug 2024 19:39:47 +0000 https://blog.monsieurwinner.com/?p=730 The code below is written in D365FO. public Description dateInWord(TransDate _date) { Description day, month, year; day = int2Str(dayOfMth(_date)); month

The post How to convert from date to string using x++ appeared first on Monsieur Winner.

]]>
The code below is written in D365FO.

    public Description dateInWord(TransDate _date)
    {
        Description day, month, year;

        day = int2Str(dayOfMth(_date));
        month = mthName(mthOfYr(_date));
        Year  = int2Str(Year(_date));

        return strFmt("%1th %2, %3",day,month,Year);


    }

08/06/2024 ( MM/DD/YY) will is outputted as 6th August, 2024

The post How to convert from date to string using x++ appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/08/06/how-to-convert-from-date-to-string-using-x/feed/ 0 730
Cannot Login after database refresh dynamics 365 FO on Premise https://blog.monsieurwinner.com/2024/04/15/cannot-login-after-database-dynamics-365-fo-on-premise/ https://blog.monsieurwinner.com/2024/04/15/cannot-login-after-database-dynamics-365-fo-on-premise/#respond Mon, 15 Apr 2024 21:43:19 +0000 https://blog.monsieurwinner.com/?p=720 It is quite easy to do an SQL DB backup and restore. This happens often on a D365FO on-premises deployment

The post Cannot Login after database refresh dynamics 365 FO on Premise appeared first on Monsieur Winner.

]]>
It is quite easy to do an SQL DB backup and restore. This happens often on a D365FO on-premises deployment from Production to UAT.

It gets a bit funnier when after the restore I get the message :

D365FO : You are not authorized to login with your current credentials. You will be redirected to the login page in a few seconds.

Me: Do you realize I am an administrator ? In fact, I deployed this environment so I need access now !!!

Well, few things to do.

  • Run the Reset-DatabaseUsers.ps1 script in the infrastructure folder

.\Reset-DatabaseUsers.ps1 -DatabaseServer ‘<FQDN of the SQL server>’ -DatabaseName ‘<AX database name>’.

  • Update the networkdomain to the adfs federation service name https://fsn.contoso.com/adfs.
If you are still unable to login, then the just restored DB  did not probably Sync.
You can run a manual DB Sync on an AOS node with the following script.

A.

Go to the AXSFType directory :

cd C:\ProgramData\SF\PR-AOS-2\Fabric\work\Applications\AXSFType_App7\AXSF.Code.1.0.20240111\Packages\bin.\Microsoft.Dynamics.AX.Deployment.Setup.exe -bindir

B.

“C:\ProgramData\SF\pr-aos-2\Fabric\work\Applications\AXSFType_App7\AXSF.Code.1.0.20240111\Packages” -metadatadir “C:\ProgramData\SF\pr-aos-2\Fabric\work\Applications\AXSFType_App7\AXSF.Code.1.0.20240111\Packages” -sqluser “axdbadmin” -sqlserver “XXX” -sqldatabase “axdb” -setupmode “sync” -syncmode “fullall” -isazuresql “false” -sqlpwd “yourdbPass

Replace the portions in bold based on your environment.

Once DB Sync is completed successfully , Happy on-premising :D.

The post Cannot Login after database refresh dynamics 365 FO on Premise appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/04/15/cannot-login-after-database-dynamics-365-fo-on-premise/feed/ 0 720
Document failed to upload. Please try to upload the document again D365FO on premises https://blog.monsieurwinner.com/2024/04/08/document-failed-to-upload-please-try-to-upload-the-document-again-d365fo-on-premises/ https://blog.monsieurwinner.com/2024/04/08/document-failed-to-upload-please-try-to-upload-the-document-again-d365fo-on-premises/#respond Mon, 08 Apr 2024 08:18:35 +0000 https://blog.monsieurwinner.com/?p=715 After a fresh deployment of D365 FO on-premises, you might encounter the error “Bond Fair Value Report failed to upload.

The post Document failed to upload. Please try to upload the document again D365FO on premises appeared first on Monsieur Winner.

]]>
After a fresh deployment of D365 FO on-premises, you might encounter the error “Bond Fair Value Report failed to upload. Please try to upload the document again.” while attaching a file on all form.

 

This is because the “documents” folder in the file server is missing.

Go to aos-storage and create a new folder “documents” and you should be fine.

failed to upload. Please try to upload the document again D365FO on premises
failed to upload. Please try to upload the document again D365FO on premises

 

The post Document failed to upload. Please try to upload the document again D365FO on premises appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/04/08/document-failed-to-upload-please-try-to-upload-the-document-again-d365fo-on-premises/feed/ 0 715
Unable to get file endpoint, the network name cannot be found – D365FO on-premises https://blog.monsieurwinner.com/2024/03/29/unable-to-get-file-endpoint-the-network-name-cannot-be-found-d365fo-on-premises/ https://blog.monsieurwinner.com/2024/03/29/unable-to-get-file-endpoint-the-network-name-cannot-be-found-d365fo-on-premises/#respond Fri, 29 Mar 2024 17:07:10 +0000 https://blog.monsieurwinner.com/?p=710 D365 FO on premises installation.   This error occurs when the local agent tries to download the package from LCS.

The post Unable to get file endpoint, the network name cannot be found – D365FO on-premises appeared first on Monsieur Winner.

]]>
D365 FO on premises installation.

 

This error occurs when the local agent tries to download the package from LCS. This file is saved in the fileshare VM.

When the fileshareLocation  value is different what is specified in the localagent-config.json is different from FileShare path in ConfigTemplate.xml,

I am happy to tell you that you just successfully landed yourself a bonus error.

 

The post Unable to get file endpoint, the network name cannot be found – D365FO on-premises appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/03/29/unable-to-get-file-endpoint-the-network-name-cannot-be-found-d365fo-on-premises/feed/ 0 710
Default model for new projects in Visual studio D365FO https://blog.monsieurwinner.com/2024/02/27/default-model-for-new-projects-in-visual-studio-d365fo/ https://blog.monsieurwinner.com/2024/02/27/default-model-for-new-projects-in-visual-studio-d365fo/#respond Tue, 27 Feb 2024 22:23:32 +0000 https://blog.monsieurwinner.com/?p=706 While creating a new Project in D365FO, you will agree with me that, the default model is the famous FleetManagement. To

The post Default model for new projects in Visual studio D365FO appeared first on Monsieur Winner.

]]>
While creating a new Project in D365FO, you will agree with me that, the default model is the famous FleetManagement.

To set your custom model as default, go to

C:\Users\XYZ\Documents\Visual Studio Dynamics 365

 

Edit the DynamicsDevConfig file.

 

<DefaultModelForNewProjects>FleetManagement</DefaultModelForNewProjects>

Change FleetManagement to your custom model.

The post Default model for new projects in Visual studio D365FO appeared first on Monsieur Winner.

]]>
https://blog.monsieurwinner.com/2024/02/27/default-model-for-new-projects-in-visual-studio-d365fo/feed/ 0 706