mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-06-09 15:07:49 +00:00
18 lines
684 B
SQL
18 lines
684 B
SQL
-- Hapus open_house dan close_house rows dengan effective_date baru
|
|
DELETE FROM house_depreciation_standards
|
|
WHERE house_type IN ('open_house', 'close_house') AND effective_date = '2026-05-29';
|
|
|
|
-- Hapus kolom multiplication_percentage
|
|
ALTER TABLE house_depreciation_standards DROP COLUMN multiplication_percentage;
|
|
|
|
-- Invalidate snapshot cache
|
|
DELETE FROM farm_depreciation_snapshots;
|
|
|
|
-- Kembalikan unique constraint lama
|
|
ALTER TABLE house_depreciation_standards
|
|
DROP CONSTRAINT house_depreciation_standards_house_type_day_eff_unique;
|
|
|
|
ALTER TABLE house_depreciation_standards
|
|
ADD CONSTRAINT house_depreciation_standards_house_type_day_unique
|
|
UNIQUE (house_type, day);
|