/*3. How to grant permission to a user to select only from localhost. */ /*Syntax : grant [|] on [database].[|] to [user name]@[||] identified by ["password"]; */ grant select on posts.* to ramaswamy@localhost identified by 'mypassword'; flush privileges;