From 6f5d91fbab966d627e28f8269dae97f1f88ccfbe Mon Sep 17 00:00:00 2001 From: Paul-Christian Volkmer Date: Fri, 13 Nov 2026 10:44:18 +0100 Subject: feat: check required form revision range --- .../resources/dev/dnpm/oshelper/migration/README.md | 18 ++++++++++++++++++ .../dev/dnpm/oshelper/migration/updatednpm_001.sql | 4 ++++ 2 files changed, 22 insertions(+) create mode 100644 src/main/resources/dev/dnpm/oshelper/migration/README.md (limited to 'src/main/resources') diff --git a/src/main/resources/dev/dnpm/oshelper/migration/README.md b/src/main/resources/dev/dnpm/oshelper/migration/README.md new file mode 100644 index 0000000..14a530b --- /dev/null +++ b/src/main/resources/dev/dnpm/oshelper/migration/README.md @@ -0,0 +1,18 @@ +# Format der Migrationsdateien + +Die Migrationsdateien sollen fortlaufend aufsteigend nummeriert sein, mit `.sql` enden. + +Zudem sollen sie immer Angaben zum betreffenden Formular und Revision enthalten: + +```sql +-- form: DNPM Beispiel +-- min-rev: 1 +-- max-rev: 2 + +ALTER TABLE dk_dnpm_beispiel + MODIFY COLUMN langer_text text; +``` + +Ist keine Angabe zum Formularnamen angegeben, wird die Migration immer ausgeführt, +anderenfalls nur für eine entsprechende Revision des angegebenen Formulars. +Wenn nicht angegeben, ist die minimal erforderliche Revision ist standardmäßig 0, die maximale 99999999999999. \ No newline at end of file diff --git a/src/main/resources/dev/dnpm/oshelper/migration/updatednpm_001.sql b/src/main/resources/dev/dnpm/oshelper/migration/updatednpm_001.sql index 44c6edc..6c6d80b 100644 --- a/src/main/resources/dev/dnpm/oshelper/migration/updatednpm_001.sql +++ b/src/main/resources/dev/dnpm/oshelper/migration/updatednpm_001.sql @@ -1 +1,5 @@ +-- form: DNPM UF Einzelempfehlung +-- min-rev: 273 +-- max-rev: 273 + ALTER TABLE dk_dnpm_uf_einzelempfehlung MODIFY COLUMN studie VARCHAR(255); \ No newline at end of file -- cgit v1.2.3