Fix: Replace deprecated double(11,2) with decimal(10,2) in ext_tables.sql#710
Fix: Replace deprecated double(11,2) with decimal(10,2) in ext_tables.sql#710kitzberger wants to merge 1 commit intoextcode:mainfrom
Conversation
….sql The ext_tables.sql file used the deprecated MySQL syntax `double(11,2)` for decimal fields, which causes constant schema migration prompts when running DB compare. MySQL/MariaDB interprets `double(11,2)` ambiguously, and Doctrine DBAL schema comparison detected a type mismatch between the defined schema and what TYPO3 generates from TCA configuration. The TCA defines these fields as `type => 'number'` with `format => 'decimal'`, which TYPO3's DefaultTcaSchema class converts to decimal(10,2). This change replaces all occurrences of `double(11,2)` with `decimal(10,2)` to align with TYPO3's schema generation and eliminate the persistent migration warnings. Affected fields: - tx_cart_domain_model_order_item: gross, net, total_gross, total_net - tx_cart_domain_model_order_taxclass: calc - tx_cart_domain_model_order_tax: tax - tx_cart_domain_model_order_product: price, discount, gross, net, tax - tx_cart_domain_model_order_discount: gross, net, tax - tx_cart_domain_model_order_shipping: gross, net, tax - tx_cart_domain_model_order_payment: gross, net, tax - tx_cart_domain_model_coupon: discount, cart_min_price
|
Sorry for late response.
Currently, it is possible to track rounding errors. This no longer seems to be possible. The question is whether the new notation should still store more decimal places, even if they are not used in the user output. |
Because that's what TYPO3 internally does for those TCA fields (type=number, format=decimal), as I've written in the description. (who got prices with that many digits anyway? That's 99,999,99.99! If you're selling products that expensive, you're not using TYPO3 😂) But yeah, maybe increase the field size to |
|
Not sure, but thinking about translated prices an shops like https://10micron.eu/montierungen/direct-drive-dds-montierungen/az-5000-dds a cart can reach this value quickly. |
The ext_tables.sql file used the deprecated MySQL syntax
double(11,2)for decimal fields, which causes constant schema migration prompts when running DB compare.MySQL/MariaDB interprets
double(11,2)ambiguously, and Doctrine DBAL schema comparison detected a type mismatch between the defined schema and what TYPO3 generates from TCA configuration. The TCA defines these fields astype => 'number'withformat => 'decimal', which TYPO3's DefaultTcaSchema class converts to decimal(10,2).This change replaces all occurrences of
double(11,2)withdecimal(10,2)to align with TYPO3's schema generation and eliminate the persistent migration warnings.Affected fields:
Resolves: #711