Search code examples
mysqlsqlcreate-table

SQL Error in Table Creation


I want to create table Books, My syntax:

enter image description here

What is wrong with my code?


Solution

  • You're using angle brackets (<>) where you should be using parentheses (()).

    CREATE TABLE books (
        isbn INT PRIMARY KEY,
        title VARCHAR (20),
        price DOUBLE
    );