solgenomics / Tea

code and database for the expression query, mining, analysis, and visualization tools
MIT License
6 stars 5 forks source link

Missing 'users' table in create_tea_schema.sql #88

Open volcanihpc opened 5 months ago

volcanihpc commented 5 months ago

Hello,

I'm getting this error when trying to open the expression viewer -

DBD::Pg::st execute failed: ERROR: relation "users" does not exist [error] Caught exception in Tea::Controller::Expression_viewer->index "ERROR: relation "users" does not exist

Thanks, I hope this project isn't dead.

noefp commented 5 months ago

Hello,

I think it might be something related with a user DB I added for some projects and might need some changes in the schema to work. I should have added it to the create_tea_schema.sql

Please try this:

alter table project add column private integer;

CREATE TABLE private_group ( private_group_id bigserial PRIMARY KEY, name varchar(80) );

CREATE TABLE project_private_group ( project_private_group_id bigserial PRIMARY KEY, project_id bigserial REFERENCES project(project_id), private_group_id bigserial REFERENCES private_group(private_group_id) );

GRANT ALL PRIVILEGES ON private_group TO web_usr; GRANT ALL PRIVILEGES ON project_private_group TO web_usr;

The project is not dead, but unfortunately I do no have time to develop new features for it. I have developed a new tool to easily create and maintain genomic portals and gene expression atlases. This one is much easier to install and we are adding many new tools and removing the relational database for even simpler installation and maintenance.

https://github.com/noefp/easy_gdb https://academic.oup.com/bioinformatics/article/38/16/4048/6617345

As an example you can take a look at MangoBase.org:

https://mangobase.org/easy_gdb/tools/expression/expression_input.php

I hope it helps! Please, let me know if that fixed the problem and I will add the cahnges to the create_tea_schema.sql file

volcanihpc commented 5 months ago

Thank you for your swift response!

Unfortunately that didn't work. I noticed these tables are already in the schema file.

Thanks for suggesting easy gdb, we'll have a look at it.

noefp commented 5 months ago

Perhaps try to add this info in the tea_local.conf file:

login_host localhost login_db tea_users login_user web_usr login_psw xxxxxx

and then, create the new database and import the new schema for users:

in the postgres console: postgres=#CREATE DATABASE my_users_Db;

in bash (logindDB_schema.sql is in the import_project folder): ~$ psql –U postgres –d my_users_db –h localhost –a –f loginDB_schema.sql

I hope with that you have all the elements to avoid errors.