Save-Resource

Description

The Save-Resource cmdlet processes pending changes on resource objects obtained from the New-Resource, Search-Resources, and Get-Resource cmdlets, and submits them to the FIM service.

The Save-Resource cmdlet provides the ability to take objects from the pipeline and save them individually, as well as passing in an array of objects and processing them in a single composite operation.

Syntax

Save-Resource -Resources <PSObject[]> [-Parallel] [-Locale <string>]

Parameters

Resources

One or more resources returned from [New-Resource, [Get-Resource] or [Search-Resources] to save

Parallel

Optional. When this switch is used, the client will perform an update to the resources on multiple threads. It is recommended to pass in an array to the -Resources parameter, which will trigger a composite update instead.

Locale

Optional. Specifies the language code of the culture to save a localized representation of the resource in. This requires the appropriate language packs to be installed on the FIM/MIM Service. e.g en-US, de-de, ja-jp, es-es, it-it.

Examples

Save a single object

$obj = Get-Resource Person AccountName testuser
$obj.DisplayName = "Test User2"
Save-Resource $obj

Save multiple objects in a single composite operation

Create and save new object

Update a localized value for a resource

Last updated