Skip to content

A complete e-commerce system with PostgreSQL backend, Node.js API, and vanilla JS frontend. Ideal for CS semester projects, DBMS learning, and full-stack development practice. Includes authentication, cart management, and admin database views.

License

Notifications You must be signed in to change notification settings

umer33511/ecommerce-dbms-system

Repository files navigation

🛒 E-Commerce Database System with PostgreSQL & Node.js

A complete full-stack implementation for learning database management systems (DBMS) and web development. Built with vanilla JavaScript for maximum educational value.

🚀 Features

Database Layer

  • 6 Normalized PostgreSQL Tables (Users, Products, Orders, etc.)
  • Complex SQL Queries with JOINs and transactions
  • Secure Authentication with password hashing

Backend API

  • Node.js/Express RESTful endpoints
  • JWT Authentication middleware
  • Error Handling for database operations

Frontend

  • Pure JavaScript DOM Manipulation
  • LocalStorage Cart with DB synchronization
  • Modal-Based UI (No page reloads)

💻 Tech Stack

  • Database: PostgreSQL 15+
  • Backend: Node.js 18+, Express 4.x
  • Frontend: Vanilla JavaScript, CSS3, HTML5

📦 Installation

Prerequisites

Setup

  1. Clone the repository
    git clone https://github.com/umer33511/ecommerce-dbms-system.git
    cd ecommerce-dbms-system
  2. Database Setup
    psql -U postgres -f sql/schema.sql
    psql -U postgres -f sql/seed.sql
  3. Configure Environment
    Edit.env with your PostgreSQL Credentials
    
  4. Install Dependencies
     npm install
  5. Run the Application
    npm start

Access at: http://localhost:3000

📚 Learning Objectives

  • Understand relational database design

  • Practice SQL query optimization

  • Learn REST API development

  • Master client-server communication

🛠️ Project Structure

      ├── sql/
      │   ├── schema.sql       # Database schema
      │   └── seed.sql         # Sample data
      ├── server/              # Node.js backend
      ├── public/              # Frontend
          ├── css/
          ├── js/
          └── test3.html
 

🤝 Contribution Guidelines

  • Report bugs as GitHub Issues

  • Fork & submit Pull Requests

  • Keep code style consistent

🚑 Troubleshooting

  • "Can't connect to PostgreSQL?" → Verify credentials in .env

  • "npm install fails?" → Try npm cache clean --force

  • "Missing modules?" → Delete node_modules and re-run npm install

📜 License

MIT License - See LICENSE file

📧 Contact

For educational inquiries: umer33511@gmail.com

Project Link: https://github.com/umer33511/ecommerce-dbms-system

About

A complete e-commerce system with PostgreSQL backend, Node.js API, and vanilla JS frontend. Ideal for CS semester projects, DBMS learning, and full-stack development practice. Includes authentication, cart management, and admin database views.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published