Skip to content

Commit ca8eec4

Browse files
authored
Merge pull request MicrosoftDocs#222 from tseward/patch-1
Update Move-SPUser.md
2 parents d85c53a + 573c4f4 commit ca8eec4

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

sharepoint/sharepoint-ps/sharepoint-server/Move-SPUser.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,24 +30,34 @@ For permissions and the most current information about Windows PowerShell for Sh
3030

3131
### ------------------EXAMPLE------------------
3232
```
33-
C:\PS>Move-SPUser -Identity "DOMAIN\JaneDoe" -NewAlias "Domain\JaneSmith"
33+
C:\PS>$user = Get-SPUser -Identity "DOMAIN\JaneDoe" -Web http://webUrl
34+
C:\PS>Move-SPUser -Identity $user -NewAlias "Domain\JaneSmith" -IgnoreSid
3435
```
3536

3637
This example migrates DOMAIN\JaneDoe to the new account of DOMAIN\JaneSmith.
3738

3839
### ------------------EXAMPLE 2------------------
3940
```
40-
C:\PS>Move-SPUser -Identity "DomainA\JaneDoe" -NewAlias "DomainB\JaneDoe"
41+
C:\PS>$user = Get-SPUser -Identity "DomainA\JaneDoe" -Web http://webUrl
42+
C:\PS>Move-SPUser -Identity $user -NewAlias "DomainB\JaneDoe"
4143
```
4244

43-
This example migrates DOMAIN\JaneDoe from DomainA to the new account of DOMAINB\JaneDoe in DomainB.
45+
This example migrates DOMAIN\JaneDoe from DomainA to the new account of DOMAINB\JaneDoe in DomainB with SID History enabled.
46+
47+
### ------------------EXAMPLE 3------------------
48+
```
49+
C:\PS>$user = Get-SPUser -Identity "i:0#.w|DOMAIN\JaneDoe" -Web http://webUrl
50+
C:\PS>Move-SPUser -Identity $user -NewAlias "i:0#.W|Domain\JaneSmith" -IgnoreSid
51+
```
52+
53+
This example migrates DOMAIN\JaneDoe to the new account of DOMAIN\JaneSmith when using Windows Claims. `-IgnoreSid` must always be used with `Move-SPUser` when using a Claims Identity, such as Windows Claims.
4454

4555
## PARAMETERS
4656

4757
### -Identity
48-
Specifies the GUID or login name of the user to be returned.
58+
Specifies the `SPUser` object retrieved via `Get-SPUser`.
4959

50-
The type must be a valid login name or GUID of the user, in the form DOMAIN\username or 1234-5678-9876-0987.
60+
The type must be a valid `SPUser` object.
5161

5262
```yaml
5363
Type: SPUserPipeBind

0 commit comments

Comments
 (0)