A Guide to SQL
A Guide to SQL
9th Edition
ISBN: 9781111527273
Author: Philip J. Pratt
Publisher: Course Technology Ptr
bartleby

Concept explainers

Expert Solution & Answer
Book Icon
Chapter 3, Problem 8RQ

Explanation of Solution

SELECT statement:

It is used to retrieve information from the table or database. The syntax for the “SELECT” statement is given below:

Syntax:

SELECT * FROM table_Name;

 Example:

Creating table “EMP_1”:

 CREATE TABLE EMP_1 ( EMP_NUM CHAR(3) , EMP_LNAME VARCHAR(15) , EMP_FNAME VARCHAR(15) , EMP_INITIAL CHAR(1), EMP_HIREDATE DATE, JOB_CODE CHAR(3));

Inserting values into the table “EMP_1”:

INSERT INTO EMP_1 VALUES ('101', 'News', 'John', 'G', ' 2000-11-08', '502');

INSERT INTO EMP_1 VALUES ('102', 'Senior', 'David', 'H', ' 1989-07-12', '501');

Explanation:

  • The above query is used to create a table structure named “EMP_1” ...

Blurred answer
Knowledge Booster
Background pattern image
Computer Science
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Recommended textbooks for you
  • Text book image
    Oracle 12c: SQL
    Computer Science
    ISBN:9781305251038
    Author:Joan Casteel
    Publisher:Cengage Learning
    Text book image
    A Guide to SQL
    Computer Science
    ISBN:9781111527273
    Author:Philip J. Pratt
    Publisher:Course Technology Ptr
    Text book image
    Database Systems: Design, Implementation, & Manag...
    Computer Science
    ISBN:9781285196145
    Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
    Publisher:Cengage Learning
Text book image
Oracle 12c: SQL
Computer Science
ISBN:9781305251038
Author:Joan Casteel
Publisher:Cengage Learning
Text book image
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781285196145
Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:Cengage Learning