realise document upload - Part 1

This commit is contained in:
Josako
2024-04-30 22:47:44 +02:00
parent 602a450114
commit 9f350b5ea0
9 changed files with 128 additions and 3 deletions

View File

@@ -35,6 +35,7 @@ class Database:
"""create new database schema, mostly used on tenant creation"""
try:
db.session.execute(CreateSchema(self.schema))
db.session.execute(text(f"CREATE EXTENSION IF NOT EXISTS pgvector SCHEMA {self.schema}"))
db.session.commit()
except InternalError:
db.session.rollback()