Q
Problem solve Get help with specific problems with your technologies, process and projects.

Best way to restrict user access to columns in a table

Just wondering which of the following methods is better in restricting users from accessing the confidential columns in a table.

  1. Create a view to hide those columns and then grant select on the view to the users.
  2. Just grant select on the ordinary columns on the table to users directly.
Any performance difference between the two approaches if there are indexes created in the underlying table(s)? I appreciated your recommendations.

The answer all depends on how complex your SQL statement is. Either method works fine for most cases. But once in a while, when a view is used a complex SQL statement (i.e. in a join), it doesn't always perform as one would hope. Using Cost Based Optimization can go a long way towards helping you out. In either case, make sure that you test your method in your application.

For More Information


Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close