-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
844 additions
and
151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
DROP TABLE "latitude"."document_hierarchies";--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" DROP CONSTRAINT "document_versions_parent_id_document_versions_id_fk"; | ||
--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" ALTER COLUMN "content" SET DEFAULT '';--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" ALTER COLUMN "content" SET NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" ADD COLUMN "path" varchar NOT NULL;--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "document_uuid_commit_id_idx" ON "latitude"."document_versions" USING btree ("document_uuid","commit_id");--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" DROP COLUMN IF EXISTS "name";--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" DROP COLUMN IF EXISTS "document_type";--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" DROP COLUMN IF EXISTS "parent_id";--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" ADD CONSTRAINT "unique_document_uuid_commit_id" UNIQUE("document_uuid","commit_id");--> statement-breakpoint | ||
ALTER TABLE "latitude"."document_versions" ADD CONSTRAINT "unique_path_commit_id" UNIQUE("path","commit_id"); | ||
|
||
-- Drop triggers | ||
DROP TRIGGER IF EXISTS after_document_versions_insert ON "latitude"."document_versions"; | ||
DROP TRIGGER IF EXISTS after_document_versions_delete ON "latitude"."document_versions"; | ||
DROP TRIGGER IF EXISTS after_document_versions_update ON "latitude"."document_versions"; | ||
|
||
-- Drop functions | ||
DROP FUNCTION IF EXISTS document_versions_insert_trigger(); | ||
DROP FUNCTION IF EXISTS document_versions_delete_trigger(); | ||
DROP FUNCTION IF EXISTS document_versions_update_trigger(); |
Oops, something went wrong.