PHPackages                             quickhelper/quickorm - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. quickhelper/quickorm

ActiveLibrary[Database &amp; ORM](/categories/database)

quickhelper/quickorm
====================

ORM to manipulate databases through code without needing to write SQL queries.

v2.0.0(1y ago)22MITPHPPHP &gt;=7.2

Since Aug 31Pushed 1y ago1 watchersCompare

[ Source](https://github.com/yossef-ashraf/QuickORM)[ Packagist](https://packagist.org/packages/quickhelper/quickorm)[ RSS](/packages/quickhelper-quickorm/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

db/orm
======

[](#dborm)

This repository contains a project that leverages ORM (Object-Relational Mapping) technology to manage and interact with databases in a convenient and efficient manner. The project demonstrates how to use ORM to manipulate databases through code without needing to write SQL queries directly.

Features
--------

[](#features)

- **Simple API:** Easily manipulate databases using objects and classes.
- **Full CRUD Support:** Insert, read, update, and delete data effortlessly.
- **Dynamic Queries:** Build SQL queries dynamically with `QueryBuilder`.
- **Relationship Management:** Handle relationships between tables, including one-to-one, one-to-many, and many-to-many.
- **Database Compatibility:** Works with most relational databases supported by PDO.

Installation
------------

[](#installation)

To install `quickhelper/quickorm` via Composer, run the following command in your project directory:

```
composer require quickhelper/quickorm
```

Basic Usage
-----------

[](#basic-usage)

### Setting up a Database Connection

[](#setting-up-a-database-connection)

Configure the database connection settings in your configuration in config/database.php ;

### Creating a Model

[](#creating-a-model)

Create a model that represents a table in your database:

```
use QuickORM\Model;

class User extends Model
{
    protected $table = 'users';
}
```

### CRUD Operations

[](#crud-operations)

- **Insert a New Record:**

```
$user = new User();
$user->name = 'John Doe';
$user->email = 'john@example.com';
$user->save();
```

- **Read a Record:**

```
$user = User::find(1);
echo $user->name;
```

- **Update a Record:**

```
$user = User::find(1);
$user->name = 'Jane Doe';
$user->save();
```

- **Delete a Record:**

```
$user = User::find(1);
$user->delete();
```

### Custom Queries

[](#custom-queries)

Use `QueryBuilder` to create custom SQL queries:

```
use QuickORM\QueryBuilder;

$results = QueryBuilder::table('users')
    ->where('age', '>', 30)
    ->get();
```

### Relationship Management

[](#relationship-management)

Define relationships between models:

```
class Post extends Model
{
    protected $table = 'posts';

    public function user()
    {
        return $this->belongsTo(User::class);
    }
}

class User extends Model
{
    protected $table = 'users';

    public function posts()
    {
        return $this->hasMany(Post::class);
    }
}
```

Contents
--------

[](#contents)

- **Introduction to ORM**
- **Practical Examples**
    - Creating objects and storing them in the database
    - Retrieving data from the database
    - Updating existing data
    - Deleting data
- **Best Practices**

Project Advantages
------------------

[](#project-advantages)

- Provides a convenient way to interact with databases.
- Facilitates the process of managing software data.
- Reduces errors caused by manual SQL queries.
- Improves the efficiency and performance of applications.

How to Use
----------

[](#how-to-use)

1. **Clone the Repository:**

    ```
    git clone https://github.com/yossef-ashraf/QuickORM.git
    ```
2. **Environment Setup:**Prepare your programming environment and install all required dependencies.
3. **Running Examples:**Execute the examples included in the project to understand how to use the ORM.

Contribution
------------

[](#contribution)

We welcome contributions to enhance this project. If you would like to participate, please:

- Open an [Issue](https://github.com/yossef-ashraf/QuickORM/issues) for any questions or feedback.
- Submit a [Pull Request](https://github.com/yossef-ashraf/QuickORM/pulls) with your improvements.

License
-------

[](#license)

This project is licensed under the [MIT License](LICENSE).

---

Best regards,
[Yossef Ashraf](https://github.com/yossef-ashraf)

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance46

Moderate activity, may be stable

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity35

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~215 days

Total

2

Last Release

409d ago

Major Versions

v1.0.0 → v2.0.02025-04-04

### Community

Maintainers

![](https://www.gravatar.com/avatar/3c4054a725ba98c7f70895a16ce6e1670cfe249a3dee6417c79513cbc89d4038?d=identicon)[yossef-ashraf](/maintainers/yossef-ashraf)

---

Top Contributors

[![yossef-ashraf](https://avatars.githubusercontent.com/u/82105736?v=4)](https://github.com/yossef-ashraf "yossef-ashraf (42 commits)")

---

Tags

ormphpsql

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/quickhelper-quickorm/health.svg)

```
[![Health](https://phpackages.com/badges/quickhelper-quickorm/health.svg)](https://phpackages.com/packages/quickhelper-quickorm)
```

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k115.1M102](/packages/jdorn-sql-formatter)[illuminate/database

The Illuminate Database package.

2.8k52.4M9.4k](/packages/illuminate-database)[mongodb/mongodb

MongoDB driver library

1.6k64.0M546](/packages/mongodb-mongodb)[ramsey/uuid-doctrine

Use ramsey/uuid as a Doctrine field type.

90340.3M211](/packages/ramsey-uuid-doctrine)[reliese/laravel

Reliese Components for Laravel Framework code generation.

1.7k3.4M16](/packages/reliese-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
