Академический Документы
Профессиональный Документы
Культура Документы
Unit 1
1. Select all of the authors
2. Select all of the publishers
3. Select all of the books
4. Create a query that will produce the following:
---------------------------------------------------------------------------------------------Johnson White lives in Menlo Park,CA
Marjorie Green lives in Oakland,CA
Cheryl Carson lives in Berkeley,CA
Michael O'Leary lives in San Jose,CA
Dean Straight lives in Oakland,CA
Meander Smith lives in Lawrence,KS
Abraham Bennet lives in Berkeley,CA
Ann Dull lives in Palo Alto,CA
Burt Gringlesby lives in Covelo,CA
Charlene Locksley lives in San Francisco,CA
Morningstar Greene lives in Nashville,TN
Reginald Blotchet-Halls lives in Corvallis,OR
Akiko Yokomoto lives in Walnut Creek,CA
Innes del Castillo lives in Ann Arbor,MI
Michel DeFrance lives in Gary,IN
Dirk Stringer lives in Oakland,CA
Stearns MacFeather lives in Oakland,CA
Livia Karsen lives in Oakland,CA
Sylvia Panteley lives in Rockville,MD
Sheryl Hunter lives in Palo Alto,CA
Heather McBadden lives in Vacaville,CA
Anne Ringer lives in Salt Lake City,UT
Albert Ringer lives in Salt Lake City,UT
(23 row(s) affected)
1.
2.
3.
4.
5.
Unit 2
Retrieve all of the authors who live in California
Retrieve all of the authors who live in either California or Michigan
Retrieve all of the authors with a first name of Dean that live in California and all authors who live in Kansas
Give two methods for retrieving all of the authors with a last name between L and S, but not including those
beginning with S.
Retrive all people with a last name of Smith or any derivative
Unit 3
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
Unit 4
1. Using both a join and a subquery, select the publishers that publish business books.
2. Using both a join and a subquery, select the number of authors that wrote business books.
3. Select a price list as shown below
Publisher
Title
Price
------------------------- -------------------------------------------------------------------------------New Moon Books
You Can Combat Computer Stress!
$ 2.99
New Moon Books
Is Anger the Enemy?
$ 10.95
New Moon Books
Life Without Fear
$ 7.00
New Moon Books
Prolonged Data Deprivation: Four Case Studies
New Moon Books
Emotional Security: A New Algorithm
$ 7.99
Binnet & Hardley
Silicon Valley Gastronomic Treats
$ 19.99
Binnet & Hardley
The Gourmet Microwave
$ 2.99
Binnet & Hardley
The Psychology of Computer Cooking
$ (null)
Binnet & Hardley
Computer Phobic AND Non-Phobic Individuals: Behavior Variations
Binnet & Hardley
Onions, Leeks, and Garlic: Cooking Secrets of the Mediterranean
Binnet & Hardley
Fifty Years in Buckingham Palace Kitchens
$ 11.95
Binnet & Hardley
Sushi, Anyone?
$ 14.99
Algodata Infosystems The Busy Executive's Database Guide
$ 19.99
Algodata Infosystems Cooking with Computers: Surreptitious Balance Sheets
Algodata Infosystems Straight Talk About Computers
$ 19.99
Algodata Infosystems But Is It User Friendly?
$ 22.95
Algodata Infosystems Secrets of Silicon Valley
$ 20.00
Algodata Infosystems Net Etiquette
$ (null)
(18 row(s) affected)
4.
5.
- --------
$ 19.99
$ 21.59
$ 20.95
$ 11.95
Unit 5
1.
au_id
123-45-6789
123-45-6788
123-45-6787
au_lname
Jordan
Jonson
Miller
au_fname
Gregory
Michael
Jim
comtract
1
0
2. You have found that some of the data is incorrect, correct this data as noted below
au_id
au_lname
au_fname
comtract
123-45-6788
Johnson
Michael
0
123-45-6787
Miller
James
1
3.
You find out that Gregory Jordan died yeaterday and the publisher is pulling all of his books. So, you must
delete him from the authors table.
4. Delete all of the authors
Unit 1 solutions
1.
2.
3.
4.
5.
1.
2.
3.
4.
5.
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
Unit 5 Solutions
1.