mirror of
https://github.com/microsoft/BCQuality.git
synced 2026-10-05 14:46:55 +01:00
Add TableRelation field-length and RecordRef.Open Temp knowledge
- data-modeling: tablerelation-field-length-must-match-related-field (exact length for unconditional relations, at least the longest target when all relations are conditional; no compile-time diagnostic) - testing: recordref-open-temp-parameter-defeats-real-table-checks (a temp-opened RecordRef is empty, so existence/uniqueness checks on it never see persisted rows; cross-links use-generateguid article) - Wire both into the review leaves and register the fixture pairs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
fd59919778
commit
260d064ece
9 changed files with 248 additions and 6 deletions
|
|
@ -0,0 +1,30 @@
|
|||
table 50100 "Sample Category"
|
||||
{
|
||||
fields
|
||||
{
|
||||
field(1; "Code"; Code[20]) { }
|
||||
}
|
||||
keys
|
||||
{
|
||||
key(PK; "Code") { Clustered = true; }
|
||||
}
|
||||
}
|
||||
|
||||
table 50102 "Sample Contract"
|
||||
{
|
||||
fields
|
||||
{
|
||||
field(1; "Code"; Code[20]) { }
|
||||
// Code[10] cannot hold every "Sample Category"."Code" value (Code[20]).
|
||||
// Compiles without a diagnostic; picking a category code longer than
|
||||
// 10 characters through the lookup fails at runtime.
|
||||
field(2; "Category Code"; Code[10])
|
||||
{
|
||||
TableRelation = "Sample Category"."Code";
|
||||
}
|
||||
}
|
||||
keys
|
||||
{
|
||||
key(PK; "Code") { Clustered = true; }
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue