How to Hide Data in Oracle
Client data is sensitive, so administrators should avoid publishing private information to all network clients. To hide data in Oracle, you create a view that only returns the data you want to make available to the client. Views are small programs on the server that return a list of data, and the database administrator controls the columns returned when the user runs the view function.
Instructions
-
-
1
Open the Oracle Enterprise Manager software on your computer or the database server. Log in to the database server using the administrator username and password.
-
2
Create the view and define the query that returns the specified data. The following code returns only the first and last names of customers stored in the "customer" table:
CREATE VIEW view_customers AS
SELECT c.firstname, c.lastname
FROM customer c -
-
3
Click the "Execute" button to run the "create view" command to create your view. Oracle returns a message that indicates the view has been created successfully.
-
4
Test the view by querying its results. Type the following code in the PL/SQL editor to return view results:
select * from view_customers;
-
1