8. etapp: DDL-i genereerimine ja ülevaatus
Kompetentsi Andmete modelleerimine knobit · K-816 · Oskus
Recognises one decimal scale for every currency
Mida see tähendab
`DECIMAL(n,2)` on an amount column in a table that is not single-currency. ISO 4217's minor-unit table is not a constant 2: JPY has 0, KWD and BHD have 3. Two decimals silently round a dinar instruction and store two meaningless zeros on a yen one.
Kuidas seda hinnatakse
Flags the deficient case and passes the acceptable one. Deficient: `fact_payment.instructed_amount DECIMAL(14,2)` with `account_currency_code` ranging over ISO 4217; a KWD payment of 12.345 is stored as 12.35 and the original instruction can no longer be reproduced Acceptable: Scale set to the widest minor unit in scope (`DECIMAL(16,3)`), the per-currency minor-unit digits held in the currency reference table, and a DQ rule that an amount's minor units match its currency. Or the single-currency scope stated in the column `comment`, so the next reviewer knows `2` was a decision
Tugineb
- Recognises a physical domain differing from the logical domainK-617 · Oskus
- Explains currency minor unitsK-853 · Teadmine
Vajalik
- Puudub