Ensuring HNSW Indexes Exist #111
-
Hello. Is there an idiomatic way to ensure tables and indexes exist? Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
We will work out a way. Note that Meanwhile you can try:
for s in schema:
db.run(s)
except QueryException as e:
if e.code == 'eval::stored_relation_conflict':
logger.warning('Database already initialized.')
else:
raise For indices (every kind of indices), look for |
Beta Was this translation helpful? Give feedback.
We will work out a way. Note that
:replace
may not be what you want: it removes everything from the old relation if it exists!Meanwhile you can
try ... catch ...
in the host language. If you use Python:For indices (every kind of indices), look for
e.code == 'tx::index_already_exists'
instead.