# vaibhavviii01/eggshell-home-builder-rdbms-system architecture

> Architecture diagram of the GitHub repository vaibhavviii01/eggshell-home-builder-rdbms-system, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-07-14). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/vaibhavviii01/eggshell-home-builder-rdbms-system
- Repository: https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system

## Overview

#### Purpose and Entry Point
Eggshell Home Builder is an Oracle RDBMS implementation for managing residential development, sales, buyer selections, and construction progress. The executable database definition and operational logic are centralized in `G1_eggshell (1).sql`; supporting usage/reporting SQL is in `G1_userguide_code.sql`.

#### Core Relational Model
The schema models the builder’s core business entities: subdivisions and lots, house styles, buyers, financing/banks, contracts and sales, construction stages/progress, decorator choices, and school-district context. The design intent and entity semantics are documented in `G1_ERD.docx` and `G1_entity_description_document.docx`.

#### Asset and Inventory Domain
Subdivision, lot, and house-style records establish the inventory available for sale and construction. Lot status is a critical boundary: a lot must remain available until sale/contract processing succeeds, and database constraints/triggers prevent duplicate sale of the same lot.
- `G1_eggshell (1).sql`
- `G1_ERD.docx`

#### Sales and Contract Lifecycle
Buyer, bank, contract, and sales data form the commercial workflow. Contract pricing is calculated from the selected home/lot plus dynamically priced buyer options. The PL/SQL package `g1_eggshellHomebuilder_pkg` encapsulates this business logic rather than leaving calculations solely to clients.
- `G1_eggshell (1).sql`
- `G1_userguide_code.sql`

#### Construction and Customization Workflow
Construction is represented as stage-based progress associated with a sold/contracted home. Buyer decorator/customization choices feed into the contract and construction lifecycle. Controlled stage updates are handled through packaged PL/SQL operations, separating workflow enforcement from direct table manipulation.
- `G1_eggshell (1).sql`
- `G1_object_description_document.docx`

#### Integrity, Access, and Performance Boundaries
Oracle triggers enforce financial and inventory invariants, including preventing negative financial values and double-selling lots. Role-based access separates Sales Manager and Construction Manager capabilities. Sequences provide database-generated identifiers; indexes support frequent lookup paths. School-district data is intentionally denormalized for retrieval performance.
- `G1_eggshell (1).sql`

#### Reporting and Runtime Infrastructure
The runtime is Oracle Database with SQL and PL/SQL. Oracle `DBMS_SCHEDULER` automates daily construction-progress reporting, making scheduled reporting a database-side operational process rather than an external application service.
- `G1_eggshell (1).sql`
- `G1_userguide_code.sql`

#### Documentation Artifacts
The repository includes the logical ERD, entity definitions, and object-level descriptions needed to interpret the SQL implementation and its database objects.
- `G1_ERD.docx`
- `G1_entity_description_document.docx`
- `G1_object_description_document.docx`

Main entry points: [`G1_eggshell (1).sql`](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql) (Contracts & Sales), [`G1_userguide_code.sql`](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_userguide_code.sql) (Usage & Reporting SQL), [`G1_ERD.docx`](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_ERD.docx) (Logical ERD), [`G1_entity_description_document.docx`](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_entity_description_document.docx) (Entity Definitions)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_schema["Oracle Schema"]
  node_schema_sql["Database Definition<br/>Oracle SQL/PLSQL"]
  node_inventory[("Inventory<br/>relational domain")]
  node_lot_status["Lot Availability<br/>inventory boundary"]
  node_buyers_financing[("Buyers &amp; Financing<br/>relational domain")]
  node_contracts_sales[("Contracts &amp; Sales<br/>relational domain")]
  node_customizations[("Decorator Choices<br/>relational domain")]
  node_construction[("Construction Progress<br/>relational domain")]
end

subgraph group_operations["Database Operations"]
  node_package{{"Home Builder Package<br/>PL/SQL package"}}
  node_integrity{{"Integrity Triggers<br/>Oracle triggers"}}
  node_identifiers(("Identifier Sequences<br/>Oracle sequences"))
  node_access["Manager Roles<br/>Oracle roles"]
  node_scheduler["Daily Progress Reporting<br/>DBMS_SCHEDULER job"]
  node_usage_sql["Usage &amp; Reporting SQL<br/>SQL scripts"]
end

subgraph group_docs["Documentation"]
  node_erd["Logical ERD<br/>architecture document<br/>[G1_ERD.docx]"]
  node_entity_docs["Entity Definitions<br/>reference document"]
  node_object_docs["Object Descriptions<br/>reference document"]
end

node_schema_sql -->|"defines"| node_inventory
node_schema_sql -->|"defines"| node_buyers_financing
node_schema_sql -->|"defines"| node_contracts_sales
node_schema_sql -->|"defines"| node_customizations
node_schema_sql -->|"defines"| node_construction
node_inventory -->|"tracks"| node_lot_status
node_lot_status -->|"allows sale"| node_contracts_sales
node_buyers_financing -->|"supports"| node_contracts_sales
node_inventory -->|"provides home and lot"| node_contracts_sales
node_customizations -->|"prices options"| node_contracts_sales
node_contracts_sales -->|"initiates"| node_construction
node_package -->|"calculates pricing"| node_contracts_sales
node_package -->|"controls stage updates"| node_construction
node_integrity -->|"prevents double sale"| node_lot_status
node_integrity -->|"enforces financial rules"| node_contracts_sales
node_identifiers -.->|"generates IDs"| node_inventory
node_identifiers -.->|"generates IDs"| node_contracts_sales
node_access -.->|"governs use"| node_package
node_scheduler -->|"reports progress"| node_construction
node_usage_sql -->|"uses"| node_package
node_usage_sql -->|"supports reporting"| node_scheduler
node_erd -.->|"documents"| node_inventory
node_erd -.->|"documents"| node_contracts_sales
node_entity_docs -.->|"defines semantics"| node_schema_sql
node_object_docs -.->|"describes"| node_package

click node_schema_sql "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_inventory "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_lot_status "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_buyers_financing "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_contracts_sales "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_customizations "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_construction "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_package "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_integrity "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_identifiers "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_access "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_scheduler "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql"
click node_usage_sql "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_userguide_code.sql"
click node_erd "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_ERD.docx"
click node_entity_docs "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_entity_description_document.docx"
click node_object_docs "https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_object_description_document.docx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_schema_sql,node_inventory,node_lot_status,node_buyers_financing,node_contracts_sales,node_customizations,node_construction toneBlue
class node_package,node_integrity,node_identifiers,node_access,node_scheduler,node_usage_sql toneAmber
class node_erd,node_entity_docs,node_object_docs toneMint
```

## Components

### Oracle Schema

Core residential-builder data model and database logic.

- [Database Definition](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): Oracle SQL/PLSQL · Creates schema objects, constraints, triggers, package, roles, and scheduler job. · `G1_eggshell (1).sql`
- [Inventory](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): relational domain · Subdivisions, lots, house styles, and denormalized school-district context. · `G1_eggshell (1).sql`
- [Lot Availability](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): inventory boundary · Lots remain available until a sale succeeds. · `G1_eggshell (1).sql`
- [Buyers & Financing](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): relational domain · Buyer and bank records supporting sales. · `G1_eggshell (1).sql`
- [Contracts & Sales](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): relational domain · Commercial records for contracted and sold homes. · `G1_eggshell (1).sql`
- [Decorator Choices](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): relational domain · Buyer options with dynamic pricing. · `G1_eggshell (1).sql`
- [Construction Progress](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): relational domain · Stage-based progress for sold or contracted homes. · `G1_eggshell (1).sql`

### Database Operations

Controlled workflows, access, and scheduled reporting.

- [Home Builder Package](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): PL/SQL package · Encapsulates contract pricing and controlled stage updates. · `G1_eggshell (1).sql`
- [Integrity Triggers](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): Oracle triggers · Prevent negative financial values and duplicate lot sales. · `G1_eggshell (1).sql`
- [Identifier Sequences](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): Oracle sequences · Generate database identifiers. · `G1_eggshell (1).sql`
- [Manager Roles](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): Oracle roles · Separates Sales Manager and Construction Manager capabilities. · `G1_eggshell (1).sql`
- [Daily Progress Reporting](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_eggshell%20(1).sql): DBMS_SCHEDULER job · Automates daily construction-progress reporting. · `G1_eggshell (1).sql`
- [Usage & Reporting SQL](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_userguide_code.sql): SQL scripts · Operational examples and reporting queries. · `G1_userguide_code.sql`

### Documentation

Model and object reference artifacts.

- [Logical ERD](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_ERD.docx): architecture document · Documents entity relationships and design intent. · `G1_ERD.docx`
- [Entity Definitions](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_entity_description_document.docx): reference document · Defines schema entity semantics. · `G1_entity_description_document.docx`
- [Object Descriptions](https://github.com/vaibhavviii01/eggshell-home-builder-rdbms-system/blob/main/G1_object_description_document.docx): reference document · Describes database objects and operations. · `G1_object_description_document.docx`

## Connections

- Database Definition → Inventory: defines
- Database Definition → Buyers & Financing: defines
- Database Definition → Contracts & Sales: defines
- Database Definition → Decorator Choices: defines
- Database Definition → Construction Progress: defines
- Inventory → Lot Availability: tracks
- Lot Availability → Contracts & Sales: allows sale
- Buyers & Financing → Contracts & Sales: supports
- Inventory → Contracts & Sales: provides home and lot
- Decorator Choices → Contracts & Sales: prices options
- Contracts & Sales → Construction Progress: initiates
- Home Builder Package → Contracts & Sales: calculates pricing
- Home Builder Package → Construction Progress: controls stage updates
- Integrity Triggers → Lot Availability: prevents double sale
- Integrity Triggers → Contracts & Sales: enforces financial rules
- Identifier Sequences → Inventory: generates IDs
- Identifier Sequences → Contracts & Sales: generates IDs
- Manager Roles → Home Builder Package: governs use
- Daily Progress Reporting → Construction Progress: reports progress
- Usage & Reporting SQL → Home Builder Package: uses
- Usage & Reporting SQL → Daily Progress Reporting: supports reporting
- Logical ERD → Inventory: documents
- Logical ERD → Contracts & Sales: documents
- Entity Definitions → Database Definition: defines semantics
- Object Descriptions → Home Builder Package: describes
