GRANT ALL PRIVILEGES ON . TO 'nombre_usuario'@'localhost';
GRANT ALL PRIVILEGES ON *.* TO 'nombre_usuario'@'localhost';
Si queremos asignar permisos para ciertas acciones:
GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP
GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP
-> ON clientes.*
-> TO 'nombre_usuario'@'localhost';
use usr_mary;
create view MiVista as
select t1.Campo1, t2.Campo2
from comun.Tabla1 t1
inner join comun.Tabla2 t2 on t2.CampoLlave = t1.CampoLlaveForanea;
use usr_mary;
create view MiVista as select t1.Campo1, t2.Campo2 from comun.Tabla1 t1 inner join comun.Tabla2 t2 on t2.CampoLlave = t1.CampoLlaveForanea;