BOOK Length Decimal Туре Nulls allowed? Description Column places Text CHAR 4 No Book code BOOK CODE (primary key) CHAR 40 Book title TITLE CHAR 3 Publisher code PUBLISHER CODE 3 CHAR Book type TYPE Book price DECIMAL 4 2 PRICE CHAR Paperback (Y. N) 1 PAPERBACK

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter14: Introduction To Swing Components
Section: Chapter Questions
Problem 3RQ
icon
Related questions
Question

What are the SQL commands to create TABLE BOOK, that includes  both primary and foreign keys, with the attached image and sql commands below?? **Below is missing foreign key command and need help to identify.

 

mysql> CREATE TABLE BOOK

->(BOOK_CODE CHAR(4) PRIMARY KEY,

->TITLE CHAR(40),

->PUBLISHER_CODE CHAR(3),

->TYPE CHAR(3),

-> PRICE DECIMAL(4,2)

->PAPERBACK CHAR(1) );

BOOK
Length
Decimal
Туре
Nulls
allowed?
Description
Column
places
Text
CHAR
4
No
Book code
BOOK CODE
(primary key)
CHAR
40
Book title
TITLE
CHAR
3
Publisher code
PUBLISHER CODE
3
CHAR
Book type
TYPE
Book price
DECIMAL
4
2
PRICE
CHAR
Paperback (Y. N)
1
PAPERBACK
Transcribed Image Text:BOOK Length Decimal Туре Nulls allowed? Description Column places Text CHAR 4 No Book code BOOK CODE (primary key) CHAR 40 Book title TITLE CHAR 3 Publisher code PUBLISHER CODE 3 CHAR Book type TYPE Book price DECIMAL 4 2 PRICE CHAR Paperback (Y. N) 1 PAPERBACK
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
SQL Query
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.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT