/BookStore_SQL

A Book Store Web Application that uses a SQL database to fetch books, performs delete and update operations.

Primary LanguageJavaScript

Project Title

A Book Store web application which fetches data from a SQL database and displays them ans also performe some basic SQL fucntionalities like Updating and Deleting books from the database.

API Reference

Get all items

  GET /books

Fetches all the books from the database using the SQL command

const q = "SELECT * FROM books";

Add a book to the database

  POST /books

Adds a new book to the SQL database using the SQL command

const q = "INSERT INTO books() VALUES (?)";

Delete a book

  DELETE /books/:id

Deletes a certain book from the SQL database using the SQL command

const q = " DELETE FROM books WHERE id = ? ";

Update a book

  PUT /books/:id

Updates a certain book from the SQL database using the SQL command

const q = "UPDATE books SET `title`= ?, `decr`= ?, `price`= ?, `cover`= ? WHERE id = ?";

Book_SQL

Update_Book_SQL

Add_Book_SQL