{"id":21540522,"url":"https://github.com/othercodes/database","last_synced_at":"2025-04-10T03:33:58.821Z","repository":{"id":14846369,"uuid":"17569410","full_name":"othercodes/database","owner":"othercodes","description":"Light database abstraction layer (PDO)","archived":false,"fork":false,"pushed_at":"2023-05-31T08:28:27.000Z","size":84,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-16T02:21:54.866Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/othercodes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-09T17:26:41.000Z","updated_at":"2023-09-24T11:47:55.000Z","dependencies_parsed_at":"2022-09-23T23:41:05.597Z","dependency_job_id":null,"html_url":"https://github.com/othercodes/database","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/othercodes%2Fdatabase","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/othercodes%2Fdatabase/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/othercodes%2Fdatabase/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/othercodes%2Fdatabase/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/othercodes","download_url":"https://codeload.github.com/othercodes/database/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226123413,"owners_count":17577041,"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":[],"created_at":"2024-11-24T04:19:16.920Z","updated_at":"2024-11-24T04:19:18.527Z","avatar_url":"https://github.com/othercodes.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OtherCode Database\n\n[![Build Status](https://travis-ci.org/othercodes/database.svg?branch=master)](https://travis-ci.org/othercodes/database) [![Latest Stable Version](https://poser.pugx.org/othercode/database/v/stable)](https://packagist.org/packages/othercode/database) [![License](https://poser.pugx.org/othercode/database/license)](https://packagist.org/packages/othercode/database) [![Total Downloads](https://poser.pugx.org/othercode/database/downloads)](https://packagist.org/packages/othercode/database)\n\nLight database abstraction layer (PDO) \n\nCurrently supported:\n\n* MySQL\n* SQLite\n* Postgres\n\n## Installation\n\nTo install the package we only have to add the dependency to ***composer.json*** file:\n\n```javascript\n\"require\": {\n  \"othercode/database\": \"*\"\n}\n```\n\nAnd run the following command:\n\n\n```bash\ncomposer update\n```\n\n### Install without Composer\n\nAlso we can use this library without Composer, we only have to include in our script the **\"database/autoload.php\"** file.\n```php\nrequire_once \"database/autoload.php\".\n```\n\n## Configuration\n\nNow we have to create the instance and add a new connection to it.\n\n```php\n$db = new OtherCode\\Database\\Database();\n\n$db-\u003eaddConnection(array(\n    'driver' =\u003e 'mysql',\n    'host' =\u003e 'localhost',\n    'dbname' =\u003e 'test',\n    'username' =\u003e 'username',\n    'password' =\u003e 'password'\n));\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fothercodes%2Fdatabase","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fothercodes%2Fdatabase","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fothercodes%2Fdatabase/lists"}