Export and Persistence Cmdlets
Save-SEEnterpriseWorld
Writes a portable snapshot.
Key parameters:
-InputObject-Path-CatalogRootPath-SourceScenarioPath-SourceScenarioName-Compress
Import-SEEnterpriseWorld
Loads a saved snapshot.
Key parameters:
-Path-SkipCompatibilityCheck-PassThruEnvelope
Export-SEEnterpriseWorld
Exports a generated world into normalized artifacts.
Key parameters:
-InputObject-OutputPath-Format-Profile-IncludeManifest-IncludeSummary-CredentialExportMode-ExportedAtUtc-Overwrite-PassThru
Where the artifacts land
-OutputPath is not always the export root:
- If
-ArtifactPrefixis supplied, artifacts are written to<OutputPath>\<ArtifactPrefix>. - Otherwise, if the last segment of
-OutputPathisnormalized, that directory is the export root and artifacts are written directly into it. - Otherwise a directory named
synthetic_enterprise_export_<yyyyMMdd_HHmmss>is created under-OutputPath.
The timestamp in that derived name comes from -ExportedAtUtc, not from the clock at the moment the command runs. Two runs with the same scenario, seed, -GeneratedAt and -ExportedAtUtc therefore resolve to the same directory, which is what makes an export tree comparable or recordable by path. -ExportedAtUtc defaults to the current UTC time, so a run that does not pin it still gets a fresh directory per run.
The returned manifest's OutputPath is the resolved export root; use it rather than reconstructing the path yourself.
Re-running into the same directory
Because the derived name is a function of -ExportedAtUtc, repeating a pinned run resolves to the directory the previous run wrote. DataGen will not merge two exports into one directory — that would leave artifacts from the earlier run in place wherever the later run produced fewer of them, giving a tree matching neither export. So:
- If the export root is absent or empty, the export proceeds.
- If it already holds content and
-Overwritewas not supplied, the export fails and writes nothing. Supply-Overwrite, or a distinct-ArtifactPrefixor-OutputPath. - With
-Overwrite, the export root is replaced outright rather than written over in place. - An overwrite is refused if the export root holds anything DataGen did not export, so pointing
-OutputPathat an occupied directory cannot destroy unrelated files. Use a directory dedicated to exports.
This also protects comparisons from a stale directory: if a run fails after writing some artifacts, the next identical run refuses rather than silently leaving a partial tree in place to be compared against.
New-SECatalogDatabase
Builds a packaged catalog SQLite database from curated source material.
Key parameters:
-CatalogRootPath-OutputPath-OriginRoot-RawNamesRoot-IncludeRawNamesCache-IncludeUncuratedSources