Populating the Sample Tables

The following scripts can be used to populate the sample tables.

Tip

If you have downloaded the populated Microsoft Access MDB file you will not have to run these scripts.

Caution

Do not run the following scripts more than once. If you have primary keys defined (and you should) then running these scripts a second time will generate SQL errors. If you do not have primary keys defined you'll end up with duplicate data (and your query results will not match those shown in the examples).

The VENDORS Table

 INSERT INTO Vendors(vend_id, vend_name, vend_address, vend_city, vend_state, vend_zip) VALUES('BRS01', 'Bears R Us', '123 Main Street', 'Bear Town', 'MI', '44444'); INSERT INTO Vendors(vend_id, vend_name, vend_address, ...

Get Sams Teach Yourself SQL in 10 Minutes now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.