The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:
TypeScript analyticsbibusiness-intelligencebusinessintelligenceclojuredashboarddatadata-analysisdata-visualizationdatabasemetabasemysqlpostgrespostgresqlreportingslacksql-editorvisualization
Edit partition migration to only drop identity if it exists. (#79415)
technomancyaa6589120409
diff --git a/resources/migrations/064/20260723_query_execution_partitioned.yaml b/resources/migrations/064/20260723_query_execution_partitioned.yamlindex 20decb6dca2..1165ffb43da 100644--- a/resources/migrations/064/20260723_query_execution_partitioned.yaml+++ b/resources/migrations/064/20260723_query_execution_partitioned.yaml@@ -24,6 +24,9 @@ databaseChangeLog:id: v64.2026-07-23T11:39:56author: technomancycomment: Create partitioned query_execution table and attach old one+ # had to edit this after the fact due to issues with stats schema diverging+ # from the schema in dev/test+ validCheckSum: ANYdbms: postgresqlchanges:- sql:@@ -34,7 +37,7 @@ databaseChangeLog:PARTITION BY RANGE (started_at);SELECT setval(pg_get_serial_sequence('query_execution', 'id'),nextval(pg_get_serial_sequence('query_execution_old', 'id')));- ALTER TABLE query_execution_old ALTER COLUMN id DROP IDENTITY;+ ALTER TABLE query_execution_old ALTER COLUMN id DROP IDENTITY IF EXISTS;ALTER TABLE query_execution ATTACH PARTITION query_execution_oldFOR VALUES FROM ('1970-01-01')TO (date_trunc('month', current_timestamp + '2 months'::interval));