Saturday, December 20, 2008

Removing Shares on CRM

first, you need to find the shares that are set on the system
this sql script will list all account shares :
( by mitch milans with permission from Satoshi Kawamura http://blogs.infinite-x.net/2006/12/04/finding-crm-accounts-that-have-been-shared/) :
select
ChangedOn 'Shared on',
name 'Account Name',
fullname 'Share Name',
owneridname 'Account Owner', 'User' 'Type'
from
PrincipalObjectAccess,
FilteredAccount,
FilteredSystemUser
where
PrincipalObjectAccess.ObjectTypeCode = 1
and PrincipalObjectAccess.ObjectId = FilteredAccount.accountid
and PrincipalObjectAccess.PrincipalId = FilteredSystemUser.systemuserid
union
select
ChangedOn 'Shared On',
FilteredAccount.name 'Share Name',
FilteredTeam.name,
owneridname 'Account Owner', 'Team' 'Type'
from
PrincipalObjectAccess,
FilteredAccount,
FilteredTeam
where
PrincipalObjectAccess.ObjectTypeCode = 1
and PrincipalObjectAccess.ObjectId = FilteredAccount.accountid
and PrincipalObjectAccess.PrincipalId = FilteredTeam.teamid
order by name

set the ObjectTypeCode and FilteredEntity accordingly.

To remove the share, it may be simplest to delete the record, but seeminlgy better option will be to let the deletion service do the job after marking the records for deletion, this will mark records sharing account entity:
( http://blog.crmbuzz.net/archive/2007/05/07.aspx by Abe Saldana )
SELECT top 500000 *
into #TempPOA
FROM PrincipalObjectAccess (nolock)
where AccessRightsMask = 0 and
InheritedAccessRightsMask > 0 and
PrincipalObjectAccess.ObjectTypeCode = 1

update PrincipalObjectAccess
set InheritedAccessRightsMask = 0
where objectid in (Select #tempPOA.objectid from #tempPOA)

drop table #TempPOA

Aftr that, you need to execute the deletion service.

Saturday, October 4, 2008

Problem : Do you want to save this file? Blank.aspx?

Link to a forum response by Dave Coperham with correction to the problem :
http://forums.microsoft.com/Dynamics/ShowPost.aspx?PostID=3742159&SiteID=27

This is a problem on the client operating system, when the client does not know how to handle aspx files. It seems that the setting deletion is caused by OS update.
To correct the problem, do what dave says :
"Save the file that it is asking you to save on your desktop. Right click on it and open it. Choose to open it with Internet Exporer and choose "always use this"...

If this does not help, try uninstalling Security Update KB953838 by entering the control panel and the add/remove program, as is told on the forum resposne : http://community.dynamics.com/forums/p/4732/5985.aspx. For this assistance by network manager will be required.