Hi,
I am trying to create virtual entity data source for on prem sql server connection reference. I am able to successfully create onprem data gateway and created the connection reference using the onprem connection. I am getting this error when trying to virtual entity data source.
Failed to create entity with logical name msdyn_ec_cr73etestcaiconnection and object type code 10582. Exception: Microsoft.Crm.CrmException: Error calling /modifyPermissionsForServicePrincipal, StatusCode: NotFound, please verify that connection 11e43db6d7594112aeda8cb3dc0acbcf exists in environment 7439f892-1b1f-e871-bf55-0da6b5adca73
at Microsoft.Crm.ObjectModel.VirtualConnectorProviderService.<>c__DisplayClass19_0.<AuthorizeVirtualConnectionProviderOnConnectionReference>b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties)
at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute[TResult](ILogger logger, XrmTelemetryActivityType activityType, Func`1 func)
at Microsoft.Crm.ObjectModel.VirtualConnectorProviderService.<>c__DisplayClass12_0.<RunACLingInSync>b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)
at Microsoft.Crm.ObjectModel.VirtualConnectorProviderService.RunACLingInSync(ExecutionContext context, Entity dataSource, IOrganizationService orgService)
at Microsoft.Crm.Metadata.EntityService.<>c__DisplayClass65_0.<OnCreateOfVirtualEntity>b__0()
at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute(ILogger logger, EventId eventId, ActivityType activityType, Action action, IEnumerable`1 additionalCustomProperties)
at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute(ILogger logger, XrmTelemetryActivityType activityType, Action action)
at Microsoft.Crm.Metadata.EntityService.OnCreateOfVirtualEntity(IEntityInfo entityInfo, IMetadataHelper metadataHelper, ExecutionContext context)
at Microsoft.Crm.Metadata.EntityService.CreateInternalHelper(EntityCreateInfo entityInfo, MetadataHelper metadataHelper, Boolean shouldCreateOnlyFromReserve, ExecutionContext context)