Cmdlets for WordPress

Build 24.0.9060

Remove-Wordpress Cmdlet

Parameters   Output Objects  

Deletes WordPress data.

Syntax

Remove-Wordpress [parameters]

Remarks

The Remove-Wordpress cmdlet allows you to use a syntax similar to SQL DELETE statements to delete WordPress data.

$conn = Connect-Wordpress -Url 'http://www.yourwordpresshost.com' -User 'yourUserName' -Password 'yourPassword'
Remove-Wordpress -Connection $conn -Table "Categories" -Id "25"
The Where parameter can also be used to specify the primary key:
Remove-Wordpress -Connection $conn -Table "exTablePowershell;" -Where "Id = 25"
The primary key can also be passed to the cmdlet along the pipeline:
Select-Wordpress -Connection $conn -Table Categories -Where "Id = '1668776136772254'" | Remove-Wordpress

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 24.0.9060