• unknown's avatar
    Bug #20363: Create view on just created view is now denied · e7daa497
    unknown authored
    There was a wrong determination of the DB name (witch is 
    not always the one in TABLE_LIST because derived tables
    may be calculated using temp tables that have their db name
    set to "").
    The fix determines the database name according to the type 
    of table reference, and calls the function check_access() 
    with the correct db name so the correct set of grants is found.
    
    
    mysql-test/r/view_grant.result:
      testsuite for the bug
    mysql-test/t/view_grant.test:
      testsuite for the bug
    sql/sql_parse.cc:
      correct determination of the db name.
    e7daa497
sql_parse.cc 217 KB