SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Viewing a view problem (permissions)
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

boing
Starting Member

8 Posts

Posted - 09/05/2006 :  07:25:15  Show Profile  Click to see boing's MSN Messenger address  Reply with Quote
Hi,

Here's my problem - I want our normal SQL users, called 'WebUser' to be able to view a view called 'sjView'...However, the table(s) this view is made up of is not accessible by WebUser, hence causing a permissions error when trying to look at it. I tried to give the view SELECT permissions etc to WebUser, but this didn't work - It just allowed me to view the view code etc.

Overall, what I want is WebUser to be able to view the sjView table, but not the tables it derives from.


How is this possible?

Thanks,
Cormac Redmond

Edited by - boing on 09/05/2006 07:26:03

SwePeso
Patron Saint of Lost Yaks

Sweden
30265 Posts

Posted - 09/05/2006 :  07:42:06  Show Profile  Visit SwePeso's Homepage  Reply with Quote
GRANT SELECT ON sjView TO WebUser did not work?


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

harsh_athalye
Flowing Fount of Yak Knowledge

India
5581 Posts

Posted - 09/05/2006 :  07:44:26  Show Profile  Visit harsh_athalye's Homepage  Click to see harsh_athalye's MSN Messenger address  Send harsh_athalye a Yahoo! Message  Reply with Quote


Harsh Athalye
India.
"Nothing is Impossible"

Edited by - harsh_athalye on 09/05/2006 07:50:59
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

Sweden
30265 Posts

Posted - 09/05/2006 :  07:48:44  Show Profile  Visit SwePeso's Homepage  Reply with Quote
This works for me
DENY SELECT ON [Table_Name] TO [Webuser] CASCADE 
GRANT SELECT ON [sjView] TO [Test]
When logging in as WebUser, SELECT * FROM Table_Name throws an error, but SELECT * FROM sjView workd great!


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

boing
Starting Member

8 Posts

Posted - 09/05/2006 :  11:48:14  Show Profile  Click to see boing's MSN Messenger address  Reply with Quote
Thanks, that worked nicely!
I never did GRANT SELECT ON [sjView] TO [Webuser], but I did give sjView SELECT permissions to Webuser from Enterprise Manager, which I presumed would do the same thing. What's the difference?
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000