Hi,
- You don't have permission to use SELECT statement on this Database "prithivnediyo" for the Login you have used.
- You have to grant the SELECT Permission to the User what you have used to login...
Try to identify the 'SELECT' permission availability on 'prithivnediyo' database for the user
USE prithivnediyo
GO
IF EXISTS(SELECT 1 FROM fn_my_permissions(NULL,'DATABASE')
WHERE permission_name='SELECT')
SELECT 'The User ''' + SUSER_SNAME() + ''' have ''SELECT'' permission on ''' + DB_NAME() + ''' database' 'Permission'
ELSE
SELECT 'The User ''' + SUSER_SNAME() + ''' doesn''t have ''SELECT'' permission on ''' + DB_NAME() + ''' database' 'Permission'
Solution:
1. Login into "Sysadmin" role login (sa) or some thing else.. if any
2. Use the following Statement...
Use prithivnediyo
Go
GRANT SELECT TO <Your UserName>
Now, login into the User as you used earliar and try the SELECT statement on this database (prithivnediyo)
Cheers
Cheers
www.SQLServerbuddy.blogspot.com
iLink Multitech Solutions
Vanchi050585, if this helps please login to Mark As Answer. | Alert Moderator