Tuesday, January 27, 2015

Retrieving Data from Oracle Database Tables


Here you can know how to regain the data from Oracle Database Tables. This lessons can be very helpful for the oracle Database learners. Hope you can easily understand this.

For retrieving the data you can apply SELECT  statement. How can you do so? For this you look the below statements by which you can retrieve the data in the various
forms.

If you want to know the employee id,  first name, last name, salary from the employees table, you can apply the following SQL statement.

select employee_id, first_name, last_name, salary from employees;

See the image of the result of that SQL statement that can make you more clear about retrieving data.

Retrieving data from employees table in oracle database
Retrieving data from employees table in oracle database
Here I am giving you the SQL statements. By them you can get the various data from the employees table.

If you want to know the last name, one year salary of the employees, apply this statement:

select last_name, salary*12 from employees;

you can change 'salary*12'. along with the change of 'salary*12' the employees salary result is changeable. If you want to know the six months salary of the employees, you use this 'salary*6'. Thus you can get the various types of salary from employees table.

If you want to know the all kinds of information(first_name, employee_id, last_name, email, phone_number, hire_date, job_id, salary, commission_pct, manager_id, department_id) from the employees table, you can use this following statement:

select * from employees;




No comments:

Post a Comment

Contact Form

Name

Email *

Message *