If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Sybase > Grant permissions to a user : "ALL TABLES"

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-14-05, 09:40
jb081177 jb081177 is offline
Registered User
 
Join Date: Feb 2005
Posts: 1
Grant permissions to a user : "ALL TABLES"

Sybase manual (http://manuals.sybase.com/onlinebook...eric__BookView)
describes the following syntax for Grant command:

grant {all [privileges]| permission_list}
on { table_name [(column_list)]
| view_name[(column_list)]
| stored_procedure_name}
to {public | name_list | role_name}
[with grant option]

But I could not find any option where I can grant specific/permissions for ALL TABLES (of a database), to a particular user.

Any clues??

Regards
Javed
Reply With Quote
  #2 (permalink)  
Old 02-14-05, 15:53
xmwolverine xmwolverine is offline
Registered User
 
Join Date: Dec 2004
Posts: 25
there is no command to 'grant to all tables'.

you can use this alternative.
use <db>
go
select 'grant all on' + name + 'to public'
from sysobjects
where type = 'U'
go

use the output of this sql to grant permissions. rename 'public' with the respective user or group if you do not want to grant the rights to all users in the database.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On