Inserting Data into the Resume Table

Once the table has been created, and before any data can be retrieved, data must be added to the table using the INSERT command. The first row is added to the RESUME table as follows.

If you enter:

INSERT INTO RESUME
     VALUES ('R323','Perkins, Alice','Snr Engineer',
             'M.B.A. 1984 George Washington Univ',
             'Presently employed at ...') ;

Syntax Notes:

  • Columns defined as CHAR (character) and VARCHAR (variable length character) have values enclosed in single quotes.

  • Parentheses must be placed around the set of data values.

  • Each data value is separated by a comma.

  • A long full text column such as job experience, would be loaded by a program function rather than manually typed in.

In the above statement, one row of data was stored in the RESUME table. Figure here shows the RESUME table after the first record has been added.

 

RES_ID RNAME          JOB          EDUC       EXP

R323   Perkins, Alice Snr Engineer M.B.A. ... Presently employed ...

Figure: RESUME Table with One Row Inserted

To add the second row into the RESUME table, you enter the INSERT command again.

If you enter

INSERT INTO RESUME
     VALUES ('R421','Smith, James','Jr Analyst',
             'B.A. 1982 Radford University'
             'Experience has been in ...') ;

Figure here shows the contents of the RESUME table after two rows have been added.

 

RES_ID RNAME          JOB          EDUC       EXP

R323   Perkins, Alice Snr Engineer M.B.A. ... Presently employed ...
R421   Smith, James   Jr Analyst   B.A. ...   Experience has been ...

Figure: RESUME Table with Two Rows Inserted

Additional INSERT commands are used to enter the RESUME data, as was illustrated in Figure here. A more complete description of the INSERT command appears in Chapter here.


Copyright © Thunderstone Software     Last updated: Apr 15 2024
Copyright © 2024 Thunderstone Software LLC. All rights reserved.