1.

What is the difference between a CREATE and SELECT command in SQL? Give an example of CREATE command

Answer»
SELECT INTO commandCREATE VIEW command
SELECT INTO creates a new table by extracting data from other tableThe CREATE VIEW creates view from a table.
Resides physically in the database.Not a part of the database's physical representation. 
Used to create backup copies of tablesNot used for backup purpose
For eg. SELECT Lastname, FirstName INTO Person_Backup FROM PersonsFor eg. CREATE VIEW v_student AS SELECT Roll_no, Name, Class FROM student;


Discussion

No Comment Found

Related InterviewSolutions