Files
PromptTech/backend/drop_price_constraints.sh

10 lines
357 B
Bash
Executable File

#!/bin/bash
# Drop check constraints on services and products tables
# Run with: sudo ./drop_price_constraints.sh
sudo -u postgres psql -d prompttech << 'SQL'
ALTER TABLE services DROP CONSTRAINT IF EXISTS chk_services_price_positive;
ALTER TABLE products DROP CONSTRAINT IF EXISTS chk_products_price_positive;
\echo 'Constraints dropped successfully'
SQL