14 lines
667 B
MySQL
14 lines
667 B
MySQL
|
|
-- Increase expected_value precision from numeric(10,2) to numeric(10,4)
|
||
|
|
-- numeric(10,2) rounds each participant's EV to 2dp; across 20 drivers the
|
||
|
|
-- accumulated rounding can exceed 0.05, pushing the total above 340.
|
||
|
|
-- numeric(10,4) limits per-participant error to ±0.00005 (total <0.001).
|
||
|
|
|
||
|
|
ALTER TABLE "participants"
|
||
|
|
ALTER COLUMN "expected_value" TYPE numeric(10,4) USING expected_value::numeric(10,4);
|
||
|
|
|
||
|
|
ALTER TABLE "participant_expected_values"
|
||
|
|
ALTER COLUMN "expected_value" TYPE numeric(10,4) USING expected_value::numeric(10,4);
|
||
|
|
|
||
|
|
ALTER TABLE "participant_ev_snapshots"
|
||
|
|
ALTER COLUMN "calculated_ev" TYPE numeric(10,4) USING calculated_ev::numeric(10,4);
|