When queries are run by having nested user-defined functions (UDFs) in Microsoft SQL Server 2019, an access violation (AV) error occurs if the query involves columns that have Dynamic Data Masking (DDM) or data classification defined on them.
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
This problem is fixed in the following cumulative update for SQL Server:
Each new cumulative update for SQL Server contains all the hotfixes and security fixes that were in the previous build. We recommend that you install the latest build for your version of SQL Server:
Learn about the terminology that Microsoft uses to describe software updates.