Purview: How to exclude folder, but not its contents from scan?

Suranga Kasturi 5 Reputation points


I'm trying to setup a scan. I've noticed that purview includes 'object type' folders as 'assets', which doesn't work for me.

As an example, consider a folder named F1 has files D1 and D2. I want D1 & D2 recognized as assets, but not F1, because on its own, its not an usable asset to me.

Of course, I could go in and delete them after a scan is completed, but would prefer to exclude them during the scan itself.

Microsoft Purview
Microsoft Purview
A Microsoft data governance service that helps manage and govern on-premises, multicloud, and software-as-a-service data. Previously known as Azure Purview.
753 questions
{count} vote

1 answer

Sort by: Most helpful
  1. BhargavaGunnam-MSFT 21,336 Reputation points Microsoft Employee

    Hello Suranga Kasturi,

    Welcome to the MS Q&A platform.

    To exclude certain assets during scanning, you can define regular expressions (regex) in the Ignore patterns. During scanning, Microsoft Purview will compare the asset's URL against these regular expressions. All assets matching any of the regexes mentioned will be ignored while scanning.

    To access the Ignore patterns , follow these steps:

    • Go to the Scan rule sets page.
    • Select the scan rule set you want to edit.
    • In the Scan rule set page, select the Ignore Patterns tab.

    You can use the regex expression:

    https://bhargavasynapsegen2.dfs.core.windows.net/card$ (this will ignore the folders but not the contents)

    Using the above expression, the scan ignores the card folder but will scan inside the files.

    Without ignore patterns:
    User's image

    With ignore patterns.

    Assets discovered is only 6(ignored my folder-card)

    User's image

    Reference document:


    I hope this helps. Please let me know if you have any further questions.

    0 comments No comments