Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1146 Table superset.ab_permission_view_role doesn't exist #219

Open
dgleba opened this issue Jul 4, 2021 · 2 comments
Open

1146 Table superset.ab_permission_view_role doesn't exist #219

dgleba opened this issue Jul 4, 2021 · 2 comments

Comments

@dgleba
Copy link

dgleba commented Jul 4, 2021

When I use the mysql example in the examples folder, I do docker-compose up.
Then, I get the following error.

 File "/usr/local/lib/python3.8/site-packages/MySQLdb/connections.py", line 224, in query
    _mysql.connection.query(self, query)
sqlalchemy.exc.ProgrammingError: (MySQLdb._exceptions.ProgrammingError) (1146, "Table 'superset.ab_permission_view_role' doesn't exist")
[SQL: SELECT ab_permission_view.id AS ab_permission_view_id, ab_permission_view.permission_id AS ab_permission_view_permission_id, ab_permission_view.view_menu_id AS ab_permission_view_view_menu_id 
FROM ab_permission_view INNER JOIN ab_permission_view_role ON ab_permission_view.id = ab_permission_view_role.permission_view_id INNER JOIN ab_role ON ab_role.id = ab_permission_view_role.role_id INNER JOIN ab_permission ON ab_permission.id = ab_permission_view.permission_id INNER JOIN ab_view_menu ON ab_view_menu.id = ab_permission_view.view_menu_id 
WHERE ab_permission.name = %s AND ab_role.id IN (%s)]
[parameters: ('menu_access', 2)]
(Background on this error at: http://sqlalche.me/e/13/f405)

@dgleba
Copy link
Author

dgleba commented Jul 4, 2021

Answering my own question.

If anyone may have any comments, please let me know.


After reading #135

I did the following. Pasting the following into a terminal, it creates a script file and runs it. It starts up the mysql db, waits, then runs superset-init, then starts superset.

This is working for me. It seems to start things in a specific order and in an orderly fashion.

cd /srv/dkr/472dkrcollection/superset_595_b_yard/superset595amanc
#
filen=./_start-amanc.sh
#
tee $filen <<- 'EOF'
docker-compose -f docker-compose.yml up -d redis mysql adminer 
s=129 ; read  -rsp $"Wait $s seconds or press Escape-key or Arrow key to continue..." -t $s -d $'\e'; echo;echo;
#
docker-compose   run --rm  superset bash superset-init
s=19 ; read  -rsp $"Wait $s seconds or press Escape-key or Arrow key to continue..." -t $s -d $'\e'; echo;echo;
#
docker-compose -f docker-compose.yml up -d superset 
s=39 ; read  -rsp $"Wait $s seconds or press Escape-key or Arrow key to continue..." -t $s -d $'\e'; echo;echo;
echo 
echo You can try to log in now.
echo
EOF
chmod +x $filen;
# start it up..
  $filen;

I put all my code here..

https://github.com/dgleba/472dkrcollection/tree/master/superset_595_b_yard/superset595amanc

@Successahead
Copy link

When I use the mysql example in the examples folder, I do docker-compose up.

Then, I get the following error.


 File "/usr/local/lib/python3.8/site-packages/MySQLdb/connections.py", line 224, in query

    _mysql.connection.query(self, query)

sqlalchemy.exc.ProgrammingError: (MySQLdb._exceptions.ProgrammingError) (1146, "Table 'superset.ab_permission_view_role' doesn't exist")

[SQL: SELECT ab_permission_view.id AS ab_permission_view_id, ab_permission_view.permission_id AS ab_permission_view_permission_id, ab_permission_view.view_menu_id AS ab_permission_view_view_menu_id 

FROM ab_permission_view INNER JOIN ab_permission_view_role ON ab_permission_view.id = ab_permission_view_role.permission_view_id INNER JOIN ab_role ON ab_role.id = ab_permission_view_role.role_id INNER JOIN ab_permission ON ab_permission.id = ab_permission_view.permission_id INNER JOIN ab_view_menu ON ab_view_menu.id = ab_permission_view.view_menu_id 

WHERE ab_permission.name = %s AND ab_role.id IN (%s)]

[parameters: ('menu_access', 2)]

(Background on this error at: http://sqlalche.me/e/13/f405)



Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants