Edit

pac data

Import and export data from Dataverse.

Note

These commands are intend to handle configuration data. They are not suitable for large volumes of data. These commands use the Configuration Migration tool and the same limitations and recommendations apply.

These commands are only available for the .NET Full Framework version of the PAC CLI.

Commands

Command Description
pac data bulk-delete cancel Cancel a bulk delete job.
pac data bulk-delete list List bulk delete jobs in the environment.
pac data bulk-delete pause Pause a running bulk delete job.
pac data bulk-delete resume Resume a paused bulk delete job.
pac data bulk-delete schedule Schedule a bulk delete job for records in a table.
pac data bulk-delete show Show details of a specific bulk delete job.
pac data export Export data
pac data import Import data
pac data retention enable-entity Enable archival/retention for a specific table.
pac data retention list List retention policies configured in the environment.
pac data retention set Create or update a retention policy for a table.
pac data retention show Show details of a specific retention policy.
pac data retention status Check the status of a retention operation.

pac data bulk-delete cancel

Cancel a bulk delete job.

Required Parameters for data bulk-delete cancel

--id -id

The bulk delete job ID (GUID).

Optional Parameters for data bulk-delete cancel

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data bulk-delete list

List bulk delete jobs in the environment.

Optional Parameters for data bulk-delete list

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data bulk-delete pause

Pause a running bulk delete job.

Required Parameters for data bulk-delete pause

--id -id

The bulk delete job ID (GUID).

Optional Parameters for data bulk-delete pause

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data bulk-delete resume

Resume a paused bulk delete job.

Required Parameters for data bulk-delete resume

--id -id

The bulk delete job ID (GUID).

Optional Parameters for data bulk-delete resume

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data bulk-delete schedule

Schedule a bulk delete job for records in a table.

Required Parameters for data bulk-delete schedule

--entity -e

The logical name of the table (e.g., account, activitypointer).

Optional Parameters for data bulk-delete schedule

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

--fetchxml -fx

FetchXML query to filter records. If omitted, all records in the table are targeted.

--job-name -jn

A descriptive name for the bulk delete job.

--recurrence -r

Recurrence pattern for the job (e.g., FREQ=DAILY;INTERVAL=1).

--start-time -st

The scheduled start time in ISO 8601 format (e.g., 2025-06-01T00:00:00Z). Defaults to now.

pac data bulk-delete show

Show details of a specific bulk delete job.

Required Parameters for data bulk-delete show

--id -id

The bulk delete job ID (GUID).

Optional Parameters for data bulk-delete show

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data export

Export data

Required Parameters for data export

--schemaFile -sf

Schema file name. It can be created using the Configuration Migration Tool.

Optional Parameters for data export

--dataFile -df

File name for data zip file. Default data.zip

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

--overwrite -o

Allow overwrite of the output data file if it already exists.

This parameter requires no value. It's a switch.

--verbose -v

Output more diagnostic information during data import/export

This parameter requires no value. It's a switch.

pac data import

Import data

Required Parameters for data import

--data -d

Zip file or directory name with data for import.

Optional Parameters for data import

--connection-count -c

Number of parallel connections to use during import. Default: 5

--dataDirectory -dd

Deprecated: This parameter is ignored.

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

--verbose -v

Output more diagnostic information during data import/export

This parameter requires no value. It's a switch.

pac data retention enable-entity

Enable archival/retention for a specific table.

Required Parameters for data retention enable-entity

--entity -e

The logical name of the table to configure retention for.

Optional Parameters for data retention enable-entity

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data retention list

List retention policies configured in the environment.

Optional Parameters for data retention list

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data retention set

Create or update a retention policy for a table.

Required Parameters for data retention set

--criteria -c

FetchXML criteria defining which records to retain.

--entity -e

The logical name of the table to configure retention for.

Optional Parameters for data retention set

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

--recurrence -r

Recurrence pattern for the job (e.g., FREQ=DAILY;INTERVAL=1).

--start-time -st

The scheduled start time in ISO 8601 format (e.g., 2025-06-01T00:00:00Z). Defaults to now.

pac data retention show

Show details of a specific retention policy.

Required Parameters for data retention show

--id -id

The retention configuration ID (GUID).

Optional Parameters for data retention show

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

pac data retention status

Check the status of a retention operation.

Required Parameters for data retention status

--id -id

The retention operation ID (GUID).

Optional Parameters for data retention status

--environment -env

Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.

See also

Microsoft Power Platform CLI Command Groups
Microsoft Power Platform CLI overview