Concept and mechanism
A retention change can affect data already present. If partition expiry decreases from 180 to 30 days, 90-day-old partitions become expired. Do not assume the rule only applies to new partitions. Also distinguish logical expiry, background physical deletion, and recovery periods. A table no longer returning data does not prove instant removal of every copy. Before changing policy, inventory consumers, required history, and the recovery plan. The business owner should understand the effect on old reports, reprocessing, and investigations, with evidence that the new horizon meets defined requirements.
Guided application
For on-demand costs, returned rows do not equal processed bytes. On a non-clustered table, adding LIMIT while retaining columns and filters does not guarantee less scanning. Optimize projection and suitable predicates, and use estimates with their limitations. For clustered tables, the estimate can exceed actual scanning; maximumBytesBilled can reject before actual pruning is known. Publication pipelines can also change security. CREATE OR REPLACE TABLE removes existing row access policies, while TRUNCATE TABLE DML does not have that same effect. In a fictional example, deployment should validate policies before exposing the new table and test identities with allowed and denied access. The same table name does not prove the same controls.
Shorter policy, cheaper query, and rebuilt table require three distinct checks: retention, cost, and authorization.
Common pitfalls
LIMIT as per-row cost; clustered estimate as exact; expiry as instant erasure; name as policy.
Related topics: Design, governance, and identity · Quality, migration, and cutover · Streaming, time, and effects
Evaluate existing-data effects and validate security after each publication.
Reference: Manage partitioned tables · Current linked standard guide (document title v4.2); edition date unconfirmed (2026-09-30 inspection)