Symptom
If you attempt to remove more than one principal from a Data Security Profile or Business Security Profile, only the first profile gets removed.
e.g.
public static void unassignProfileTest(String principalToRemove, UniverseSecurityCache universeSecurityCache) throws SDKException {
// Unassigns the security profile
for (DataSecurityProfile securityProfile : universeSecurityCache.getDataSecurityProfiles()) { // for (BusinessSecurityProfile securityProfile : universeSecurityCache.getBusinessSecurityProfiles()) {
if (securityProfile.getName().equals(SEC_SP_NAME)) {
List<Principal> principals = universeSecurityCache.getPrincipals(securityProfile);
for (Principal tmpPrincipal : principals) {
if (tmpPrincipal.getName().equals(principalToRemove)) {
principals.remove(tmpPrincipal);
universeSecurityCache.commit();
System.out.println("The security profile has been unassigned successfully.");
break;
}
}
}
}
universeSecurityCache.close();
}
Read more...
Environment
- SAP BusinessObjects 4.3 SP2
Product
SAP BusinessObjects Business Intelligence platform 4.3
Keywords
businesssecurityprofile, security, profile, principal, remove, removal, cache, unx, universe, sdk, semantic, SL , KBA , BI-DEV-JAV , BI Software Development Kits (SDKs) - Java , Problem
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.