Skip to content

kusowl/KDAL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

KDAL - K Data Access Layer

This is a data abstraction layer for PHP, built using PHP. This library aims to be used as alternative of writing SQL. It adds an abstraction layer on top of SQL.

Example -

    // Deleting a record in MYSQL
    $sql = "DELETE from ".static::$table." WHERE id = ?";
    $stmt  = static::$pdo->prepare($sql);
    $stmt->execute([$id]);
    
    // Instead of this we can write
    $user = Users::find('[email protected]');
    $user->delete();

Features

This project is still in ALPHA stage.

  1. Mapping of Database Tables to Classes.
  2. Basic CRUD Operation
  3. Method Chaining ( Not yet )
Statement Status Test Covergae
Table Done Full
Insert Done Medium
Update Done Medium
Read Done Medium
Delete Done Medium
Create Not Yet None
Alter Not Yet None
Drop Not Yet None
Grant Not Yet None
Revoke Not Yet None
Commit Not Yet None
Rollback Not Yet None
Savepoint Not Yet None

Support

I am building, testing and using it in latest XAMPP, so it only supports PHP 8.0.

Author

Kushal Saha - [email protected] - LinkedIN

License

KDAL is licensed under the MIT License - see the LICENSE file for details

About

A simple and lightweight Database Abstraction Layer for PHP

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages