Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Trying to Write an SQL Table for Class and Keep Running into ERROR 1 0 6 4 ( 4 2 0 0 0 ) :
Trying to Write an SQL Table for Class and Keep Running into "ERROR : You have an error in your SQL syntax" Here are the Details of my Table:
mysql CREATE TABLE Customers
CustomerID INT,
FirstName VARCHAR
LastName VARCHAR
Street VARCHAR
City VARCHAR
State VARCHAR
ZipCode VARCHAR
Telephone VARCHAR
PRIMARY KEY CustomerID
;
Query OK rows affected sec
mysql DESCRIBE Customers;
Field Type Null Key Default Extra
CustomerID int NO PRI NULL
FirstName varchar YES NULL
LastName varchar YES NULL
Street varchar YES NULL
City varchar YES NULL
State varchar YES NULL
ZipCode varchar YES NULL
Telephone varchar YES NULL
rows in set sec
mysql CREATE TABLE Orders
OrderID INT,
CustomerID INT,
SKU VARCHAR
Description VARCHAR
PRIMARY KEY OrderID
FOREIGN KEY CustomerID REFERENCES Customers CustomerID
;
Query OK rows affected sec
mysql DESCRIBE Orders;
Field Type Null Key Default Extra
OrderID int NO PRI NULL
CustomerID int YES MUL NULL
SKU varchar YES NULL
Description varchar YES NULL
rows in set sec
mysql CREATE TABLE RMA
RMAID INT,
OrderID INT,
Step VARCHAR
Status VARCHAR
Reason VARCHAR
PRIMARY KEY RMAID
FOREIGN KEY OrderID REFERENCES Orders OrderID
;
Query OK rows affected sec
mysql DESCRIBE RMA;
Field Type Null Key Default Extra
RMAID int NO PRI NULL
OrderID int YES MUL NULL
Step varchar YES NULL
Status varchar YES NULL
Reason varchar YES NULL
rows in set sec
mysql INSERT INTO Customers VALUES
ThomasBonnerMy StreetTampaFL
MarlaSingerFight ClubLos AnglesCA
RobertBonnerBro CircleTampaFL
Sheldon<
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started