GBase 8a supports data masking to protect sensitive information. But when a masked column appears in a WHERE clause, a GROUP BY, an ORDER BY, or when its data is copied to another column — does the database operate on the original values or the masked values? This article clarifies the behaviour through a set of direct tests.
Test Setup
Create a table with a default masking policy on an integer column and insert sample data:
CREATE TABLE "testmask" (
"id" int(11) DEFAULT NULL MASKED WITH(FUNCTION='DEFAULT()')






