Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Trouble adding indexes #251

Closed
jefftienchow opened this Issue Jul 6, 2017 · 4 comments

Comments

Projects
None yet
3 participants

During the MIMIC database setup, I tried adding indexes using:
psql 'dbname=mimic user=mimic options=--search_path=mimiciii' -f postgres_add_indexes.sql
and I get this error:
psql:postgres_add_indexes.sql:19: NOTICE: index "admissions_idx01" does not exist, skipping
DROP INDEX
psql:postgres_add_indexes.sql:21: ERROR: relation "admissions" does not exist

How do I fix this so I can add indexes? Thanks.

Owner

alistairewj commented Jul 9, 2017

Hm two issues about this so maybe there is a subtle bug in the build scripts.

I presume you're using the terminal based approach. Can you login to the database and do run the following:

\dn
set search_path to mimiciii;
\dt

And paste the output here?

The output is:
No relations found.

Owner

alistairewj commented Jul 11, 2017

Which schemas were listed from \dn? It sounds like you have built MIMIC on a schema other than mimiciii. Check the other schemas for data.

This was fixed by creating a database with superuser privileges and granting superuser privileges to postgres. @tompollard

@tompollard tompollard closed this Jul 12, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment