0

Hi all,

I am writing a web interface which uses a MSSQL Server 2000 database. I have checked and double checked all permissions and can't find any problems but when I run a

select * from sales

I get the 'Permission denied for `sales` database `dbasename` database owner `sqluser`

I connect with the string

mssql_connect("server","sqluser","passwd");

and this connects fine, so I am attempting to select all the components from a table that the user I connect with owns. As a sideline, I can create tables, but cannot read them in any way.

Any advice would be appreciated.
Thanks

2
Contributors
1
Reply
2
Views
10 Years
Discussion Span
Last Post by pty
0

Hi all,

I am writing a web interface which uses a MSSQL Server 2000 database. I have checked and double checked all permissions and can't find any problems but when I run a

select * from sales

I get the 'Permission denied for `sales` database `dbasename` database owner `sqluser`

I connect with the string

mssql_connect("server","sqluser","passwd");

and this connects fine, so I am attempting to select all the components from a table that the user I connect with owns. As a sideline, I can create tables, but cannot read them in any way.

Any advice would be appreciated.
Thanks

try

grant select on sales to sqluser

If you look up the grant function on msdn you can finely tune the privileges for each table/database/user/whatever.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.