add features

This commit is contained in:
Matthias Hochmeister
2026-03-03 17:03:27 +01:00
parent 5a6fc85a75
commit 817329db70

View File

@@ -5,12 +5,15 @@
ALTER TABLE ausruestung_kategorien
ADD COLUMN IF NOT EXISTS motorisiert BOOLEAN NOT NULL DEFAULT FALSE;
-- Recreate the helper view to include the new column
CREATE OR REPLACE VIEW ausruestung_mit_pruefstatus AS
-- DROP + CREATE is required because CREATE OR REPLACE VIEW cannot change the
-- column list of an existing view (PostgreSQL error 42P16).
DROP VIEW IF EXISTS ausruestung_mit_pruefstatus;
CREATE VIEW ausruestung_mit_pruefstatus AS
SELECT
a.*,
k.name AS kategorie_name,
k.kurzname AS kategorie_kurzname,
k.name AS kategorie_name,
k.kurzname AS kategorie_kurzname,
k.motorisiert AS kategorie_motorisiert,
f.bezeichnung AS fahrzeug_bezeichnung,
f.kurzname AS fahrzeug_kurzname,