create table inventory
(
Books_number number (8),
Book_name varchar2 (45),
price number (5),
quantity number (5)
);
insert into inventory values (book_seq.nextval*10, 'Midnight Summer's Dream', $5.00, 5);
Asked
Active
Viewed 25 times
-3

Rory McCrossan
- 331,213
- 40
- 305
- 339

Rose E
- 7
-
In general, you have to escape apostrophes – Strawberry Oct 22 '14 at 09:44
-
possible duplicate of [How to escape apostrophe (') in MySql?](http://stackoverflow.com/questions/9596652/how-to-escape-apostrophe-in-mysql) – Ocaso Protal Oct 22 '14 at 09:44
1 Answers
1
You have an apostrophe in the book name so it's acting as a delimiter for the string. Escape that single quote character:
insert into inventory values (book_seq.nextval*10, 'Midnight Summer\'s Dream', $5.00, 5);

danmullen
- 2,556
- 3
- 20
- 28