---
id: change/bcapps/11121
type: change
title: "#11121 Fix generation rule source table validation "
summary: Fixed source table validation for quality inspection generation rules to prevent clearing the source table through programmatic modifications while allowing legacy rules without a source table to remain editable.
tier: official
language: en
tags:
  - fix
  - main
  - bc30
  - table qlty. inspection gen. rule
system: development
review:
  state: reviewed
  by: opus
  at: "2026-10-08T02:05:33.072Z"
  flags: []
generated:
  at: "2026-10-08T01:26:53.141Z"
  pipeline: 0.2.0
  prompts:
    extract-change: 1
  input_hash: d9496dbde628e2f5bc90ab7894710673c12b0521
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/pull/11121
    title: "microsoft/BCApps#11121: Fix generation rule source table validation "
    date: "2026-09-10"
    commit: d9496dbde628e2f5bc90ab7894710673c12b0521
    t: null
    quote: null
links:
  learn: []
  objects:
    - object/table/20404
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes: []
number: 11121
repo: microsoft/BCApps
source_id: bcapps-prs
url: https://github.com/microsoft/BCApps/pull/11121
kind: pr
base_branch: main
major: "30"
merged_at: "2026-09-10T10:26:19Z"
author: 6CRIPT
author_type: User
community_contribution: false
labels:
  - "AL: Apps (W1)"
  - SCM
  - "Team: SCM"
change_class: code
change_kind: fix
behavior_change: true
breaking: false
files:
  count: 1
  additions: 12
  deletions: 2
  al: 1
apps:
  - Quality Management
objects_touched:
  - key: table/20404
    page: table/20404
    type: table
    id: 20404
    name: Qlty. Inspection Gen. Rule
    app: Quality Management
    status: modified
objects_unjoined: []
obsoletions: []
backports: []
fixes_issues: []
work_items:
  - 642736
systems:
  - development
quote: null
joined_against:
  major: "30"
  commit: ecbc028c25dbe83b61313bc566e6c1d41184bb1c
---

# #11121 Fix generation rule source table validation 

> Fixed source table validation for quality inspection generation rules to prevent clearing the source table through programmatic modifications while allowing legacy rules without a source table to remain editable.

[Pull request](https://github.com/microsoft/BCApps/pull/11121) · merged into `main` (BC30) on 2026-09-10 by 6CRIPT · 1 file (+12 -2), 1 AL · fix · tier official · reviewed (checked by Opus)

## What changed

- OnModify now reads persisted generation rule data instead of relying on xRec
- Prevents accidental clearing of source table on existing rules via programmatic changes
- Legacy rules stored without source table remain editable
- Temporary records keep previous validation behavior
- Addresses issue AB#642736
- Behaviour changes for users or extensions.

## AL objects touched

- [Table 20404 "Qlty. Inspection Gen. Rule"](../../objects/table/20404.md), Quality Management: modified

## Context

- Work items: AB#642736
- Labels: AL: Apps (W1), SCM, Team: SCM
- Systems: development

Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).
