{"id":29182590,"url":"https://github.com/veddonda/myshop","last_synced_at":"2025-07-01T20:06:49.899Z","repository":{"id":301280861,"uuid":"1008742760","full_name":"VedDonda/MyShop","owner":"VedDonda","description":"This is a repository for Online Store Database (Myshop).","archived":false,"fork":false,"pushed_at":"2025-06-26T03:35:33.000Z","size":329,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-26T04:20:01.233Z","etag":null,"topics":["postgresql","sql"],"latest_commit_sha":null,"homepage":"","language":"PLpgSQL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VedDonda.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-26T03:09:22.000Z","updated_at":"2025-06-26T03:35:37.000Z","dependencies_parsed_at":null,"dependency_job_id":"a5d53873-81cf-403d-940b-475e153ebce2","html_url":"https://github.com/VedDonda/MyShop","commit_stats":null,"previous_names":["veddonda/myshop"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/VedDonda/MyShop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VedDonda%2FMyShop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VedDonda%2FMyShop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VedDonda%2FMyShop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VedDonda%2FMyShop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VedDonda","download_url":"https://codeload.github.com/VedDonda/MyShop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VedDonda%2FMyShop/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263029214,"owners_count":23402354,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["postgresql","sql"],"created_at":"2025-07-01T20:06:48.986Z","updated_at":"2025-07-01T20:06:49.898Z","avatar_url":"https://github.com/VedDonda.png","language":"PLpgSQL","funding_links":[],"categories":[],"sub_categories":[],"readme":"## 🛒 MyShop Database (PostgreSQL)\n\nThis project contains a normalized PostgreSQL database schema for an **Online Store**. The database supports essential e-commerce functionality including user management, product listing, discount handling, shopping cart and order processing, and payment tracking.\n\n---\n\n### 📁 File Structure\n\n| File Name       | Description                                                                                                                                       |\n| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `schema.sql`    | Contains the full schema: tables, fields, relationships, constraints, and indexes.                                                                |\n| `functions.sql` | Includes stored functions for business logic (e.g., stock updates, total cost calculations).                                                      |\n| `triggers.sql`  | Contains trigger functions and trigger definitions to ensure data integrity and automate tasks (e.g., setting timestamps, enforcing stock rules). |\n\n---\n\n### 🧩 Features\n\n* **User \u0026 Vendor Management**\n  Users can register as customers or vendors with role-based differentiation.\n\n* **Shops \u0026 Products**\n  Vendors can manage shops and product listings, including price and inventory.\n\n* **Discount Handling**\n  Products support time-bound percentage-based discounts.\n\n* **Cart \u0026 Orders**\n  Users can add products to carts, place orders, and track delivery status.\n\n* **Payments**\n  Orders are linked with payments, supporting method tracking and timestamps.\n\n* **Data Integrity**\n  Enforced through constraints, foreign keys, and PostgreSQL triggers.\n\n---\n\n### 🧪 Example Use Cases\n\n* Add a new product to a vendor’s shop.\n* Apply a discount to a product and query the final selling price.\n* Automatically update stock when an order is placed.\n* Calculate total order value using a function that considers discounts.\n\n---\n\n### 🧠 Skills \u0026 Concepts Used\n\n* PostgreSQL SQL and PL/pgSQL\n* Relational Database Design (Normalization, Foreign Keys)\n* Triggers and Stored Procedures\n* Time-based logic and constraints\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveddonda%2Fmyshop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fveddonda%2Fmyshop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveddonda%2Fmyshop/lists"}