Advertisement
Guest User

Untitled

a guest
Jul 8th, 2017
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. SELECT * FROM some_other_database_on_the_same_server_as_the_currently_used_database.some_table WHERE id = 1
  2.  
  3. mysql> SHOW GRANTS FOR ana_index@localhost;
  4. | GRANT USAGE ON *.* TO 'ana_index'@'localhost' IDENTIFIED BY PASSWORD '*...'
  5. | GRANT ALL PRIVILEGES ON `test`.* TO 'ana_index'@'localhost'
  6.  
  7. mysql> SELECT * FROM mysql.user WHERE user = 'ana_index'G
  8. *************************** 1. row ***************************
  9. Host: localhost
  10. User: ana_index
  11. Password: *1E62D0DB2482ED4455102B56D823285C02BAAF8F
  12. Select_priv: N
  13. Insert_priv: N
  14. Update_priv: N
  15. Delete_priv: N
  16. Create_priv: N
  17. (etc)
  18.  
  19. mysql> SELECT * FROM mysql.db WHERE user = 'ana_index'G
  20. *************************** 1. row ***************************
  21. Host: localhost
  22. Db: test
  23. User: ana_index
  24. Select_priv: Y
  25. Insert_priv: Y
  26. Update_priv: Y
  27. Delete_priv: Y
  28. Create_priv: Y
  29. Drop_priv: Y
  30. Grant_priv: N
  31. (etc)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement