Monday, February 27, 2012

Powershell alternative of stsadm -o migrateuser

Powershell alternative of stsadm -o migrateuser -oldlogin domain\oldid  -newlogin domain\newid  -ignoresidhistory

I found the following with the help of MSDN techies

Move-SPUser [-Identity] <SPUserPipeBind> -NewAlias <String> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-IgnoreSID <SwitchParameter>] [-WhatIf [<SwitchParameter>]]

Sunday, February 26, 2012

Change DisplayName after Windows ID change

In my clients  SharePoint 2010 my sites application, we were facing a strange issue. Our MySite app is integrated with enterprise AD and importing most of the properties from it. Few the users first name / last name changed recently which made changes in their AD Ids. The changes flown to user profile during next sync operation. We also executed the following MigrateUser command updates the user profile store for this user
stsadm -o migrateuser -oldlogin domain\oldid  -newlogin domain\newid  -ignoresidhistory
This resolved all the issues except the "Displayname at the top navigation still shows old name"....
Hours .... Days... tried all sorts of combinations .... At last I found the right combination
  • Process the name changes by issuing user migration (stsadm -o migrateuser)
  • Sets the ignore is active flag and deletes all profile sync log info (stsadm -o sync -ignoreisactive 1)
  • Changes the profile full sync timer job schedule temporarily  (stsadm -o sync -deleteolddatabases 0)
  • Executes profile full sync timer job

WOW Im excited :)

Saturday, February 11, 2012

Styling of Blog listing displayed in OOTB Blog site


There is an easy way to update Blog listing displayed in OOTB Blog site


Basically this is an XMLViewer webpart driven by the Blog.xsl file saved at 14Hive\Template\Layouts\XSL. To implement this


1. copy the Blog.xsl file locally and modify according to our needs
2. upload the modified xsl into sites style library
3. specify the XSL Link property under the Advanced property group of the web part