Odoo Ayuda

1

2
1 Respuesta
1
Fatih Piristine Finlandia
25/6/17 15:58

don't use database manager page for this. use pg tools with correct user credentials and you won't have any problem.

psql -h localhost -U username -d database -W < /path/to/dump.sql
password: ****


if you have any permission problems after importing the database from command line: you can fix them using the following commands on tables, views, sequences. good luck.



-- alter permissions [optional]

REASSIGN OWNED BY old_user TO newuser;


ALTER DATABASE old_user OWNER TO newuser;


Tables [ownership]

for tbl in `psql -qAt -c "select tablename from pg_tables where schemaname = 'public';" dbname` ; do psql -c "alter table $tbl owner to username" dbname ; done


Sequences [ownership]

for tbl in `psql -qAt -c "select sequence_name from information_schema.sequences where sequence_schema = 'public';" dbname` ; do psql -c "alter table $tbl owner to username" dbname ; done


View [ownership]

for tbl in `psql -qAt -c "select table_name from information_schema.views where table_schema = 'public';" dbname` ; do psql -c "alter table $tbl owner to username" dbname ; done



Realizar una pregunta
Keep Informed
1 seguidor(es)
About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

Register
Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now