-2

I am trying to create this table and I am not sure why it wont run or let me

  CREATE TABLE DRIVER (
    DRIVER_ID           INTEGER         PRIMARY KEY,
    DRIVER_NAME         VARCHAR (10)    NOT NULL,
    DRIVER_ADDRESS      VARCHAR (35)    NOT NULL,
    DRIVER_CITY             VARCHAR (35)    NOT NULL,
    DRIVER_STATE            VARCHAR (2)     DEFAULT ‘TX’,
    DRIVER_ZIP          INTEGER (5) NOT NULL
    );

This is the data I'm trying to insert into the table

INSERT INTO DRIVER (DRIVER_ID, DRIVER_NAME, DRIVER_ADDRESS, DRIVER_CITY, DRIVER_STATE, DRIVER_ZIP) 
VALUES (‘3452342’, ‘Jennifer Kay, ‘2345 Green Ave’, ‘Dallas’, ‘TX’, ‘75201’);
VALUES (‘4323462’, ‘Alex Sanchez’ , ‘326 Main Street’, ‘Plano’ , ‘TX’, ‘75074’);
VALUES (‘7994638’, ‘Rob Joe’, ‘4315 Campbell Road’ ‘Mesquite’, ‘TX’,’75150’);

Thank you for the help

mmushtaq
  • 3,430
  • 7
  • 30
  • 47
Aaron
  • 1
  • 1
  • 1
    What does "won't run or let me" mean? Are you getting an error? If so, what error? Please don't make us guess. You've specified 3 `VALUES` clauses but only one `INSERT` which won't work. In your post, you have the Microsoft curly quotes in your `DEFAULT` rather than normal single quotes. I have no idea whether either is your problem or whether those are transcription errors on your part. – Justin Cave Dec 02 '16 at 18:23

1 Answers1

0
DEFAULT ‘TX’,

there are wrong quote characters. It should be DEFAULT 'TX',. The same problem in insert statement.

Kacper
  • 4,798
  • 2
  • 19
  • 34