SQL – VIEW SQL – DUAL: Here, we will realize what is VIEW, how to make VIEW and how it thinks about the tables?
A VIEW is a virtual table, through wish we can choose a little part of the information from at least one table, and it limits the entrance on the first table/information. Any progressions done on the information in view will ponder the tables from which information is taken.
A DUAL is an exceptional one section and one line which can be utilized to do little estimations and tasks and so on.
Test table (Student),
1) Create a view from the understudy table
CREATE VIEW first_view AS SELECT student_name, City from Student;
To see this table we have to utilize the SELECT query.
SELECT * FROM first_view;
Here, first_view: it is the name of the virtual table
2) Use DUAL to get the current date
SELECT SYSDATE() FROM DUAL;
Will return the current date from the framework.