Hi,
In order to set permission for external content type, you can edit the permission in Central Administration or grant the user permission using powershell. Since you can’t grant execute permission for All Authenticated Users, you need to grant each user permission
manually. When a new user is added to a site, you need to edit the permission for the content type in Central Administration, or you can run the powershell script:
$userId="domainName\UserName"
$serviceContextURL="http://serverName:8080/"
$ECTName="ECT"
$ECTNamespace="http://demo2010a:5000"
[String[]]$permissions=@("Execute","Edit","SelectableInClients","SetPermissions")
#--------------Set Permissions to External Content Type----------------
$ECT = Get-SPBusinessDataCatalogMetadataObject -BdcObjectType "Entity" -ServiceContext $serviceContextURL -Name $ECTName -Namespace
$ECTNamespace
if($ECT -ne $null)
{
$user = New-SPClaimsPrincipal -Identity $userId -IdentityType WindowsSamAccountName
Grant-SPBusinessDataCatalogMetadataObject -Identity $ECT -Principal $user -Right $permissions
}
else
{
write-host -f Yellow $ECTName external content type does not exists
}
For more information, please refer to this site:
Set Permissions to External Content Type using Powershell:
http://www.c-sharpcorner.com/uploadfile/anavijai/set-permissions-to-external-content-type-using-powershell/
Thanks,
EnTan Ming
Entan Ming
TechNet Community Support
