Advertisement
crashwave

Script Grant Select for all Views

Jan 27th, 2021 (edited)
3,421
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.16 KB | None | 0 0
  1. /*This generates scripts to Grant Select on all views to a user %USER% */
  2. SELECT 'GRANT SELECT ON ' + TABLE_NAME + ' TO %USER%'
  3. FROM INFORMATION_SCHEMA.Views
  4.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement