Clear-AzureBizTalkTrackingStore

 

Important

Microsoft Azure BizTalk Services (MABS) is being retired, and replaced with Azure Logic Apps. If you currently use MABS, then Move from BizTalk Services to Logic Appsprovides some guidance on moving your integration solutions to Logic Apps.

If you're brand new to Logic Apps, then we suggest getting started here:

The Clear-AzureBizTalkTrackingStore clears the tracking store for your BizTalk Services subscription.

Syntax

Clear-AzureBizTalkTrackingStore -Sql <sqlstring> -AzureStore <azurestring> -Ndays <ndays> [DeleteAS2NRR] [-NoPrompt] [<CommonParameters>]

Parameters

Parameter

Requirement

Description

-Sql <SqlString>

Required

The SQL connection string to the tracking store.

-AzureStore <azurestring>

Required

The Microsoft Azure storage account connection string.

-Ndays <ndays>

Required

The number of days for which the tracking store data must be persisted, which means data older than the specified number of days is deleted. The minimum value must be 1.

DeleteAS2NRR

Optional

Specify true if you want to delete the AS2 NRR data as well. Otherwise, specify false.

[-NoPrompt]

Optional

If included, you are not prompted for a confirmation before the data is deleted from the store.

[CommonParameters]

Optional

Can be used with any cmdlet and are implemented by Windows PowerShell. Options include:

  • -Verbose

  • -Debug

  • -ErrorActions

  • -ErrorVariable

  • -WarningAction

  • -WarningVariable

  • -OutBuffer

  • -OutVariable

get-help about_commonparameters provides detailed information about these common parameters. about_CommonParameters is also a good resource.

Examples

  • Successfully clear the tracking store

    Clear-AzureBiztalkTrackingStore -Sql (Get-Content sqlString.txt) -AzureStore (Get-Content AzureStore.txt) -Ndays 2 true -NoPrompt

    Output

    Tracking records older than 2 days were purged successfully. 
    Active Batch records were cleaned successfully.
    Size of Tracking Store before purge: 5GB
    Size of Tracking Store after purge: 4.2GB
    Size of Archiving data purged: 300MB
    
  • Error when the specified URL does not exist

    Clear-AzureBiztalkTrackingStore -Sql ( Get-Content sqlString.txt) -AzureStore (Get-Content AzureStore.txt) -Ndays 2 true -NoPrompt

    Output

    Unable to connect to tracking or archiving store. Please check the URL and try again.
    

See Also

PowerShell CmdLets to manage the BizTalk Service