{"id":15024896,"url":"https://github.com/qbbr/pgsqldoctrinerandomfunction","last_synced_at":"2025-06-20T23:34:13.033Z","repository":{"id":62531461,"uuid":"53645009","full_name":"qbbr/PgsqlDoctrineRandomFunction","owner":"qbbr","description":"PostgreSQL RANDOM() function for Doctrine ORM","archived":false,"fork":false,"pushed_at":"2024-08-16T16:45:29.000Z","size":4,"stargazers_count":4,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-05T10:49:03.663Z","etag":null,"topics":["doctrine-orm","php","postgresql","symfony"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"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/qbbr.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2016-03-11T06:28:03.000Z","updated_at":"2023-01-09T09:31:36.000Z","dependencies_parsed_at":"2024-09-20T11:04:24.110Z","dependency_job_id":"94172c25-5cba-4c0c-b419-1365624b2e5a","html_url":"https://github.com/qbbr/PgsqlDoctrineRandomFunction","commit_stats":{"total_commits":5,"total_committers":2,"mean_commits":2.5,"dds":0.4,"last_synced_commit":"695404f54bccfc7f149bb24c35faf4b5318899fb"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/qbbr/PgsqlDoctrineRandomFunction","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qbbr%2FPgsqlDoctrineRandomFunction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qbbr%2FPgsqlDoctrineRandomFunction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qbbr%2FPgsqlDoctrineRandomFunction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qbbr%2FPgsqlDoctrineRandomFunction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/qbbr","download_url":"https://codeload.github.com/qbbr/PgsqlDoctrineRandomFunction/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qbbr%2FPgsqlDoctrineRandomFunction/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261036840,"owners_count":23100930,"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":["doctrine-orm","php","postgresql","symfony"],"created_at":"2024-09-24T20:01:08.457Z","updated_at":"2025-06-20T23:34:08.023Z","avatar_url":"https://github.com/qbbr.png","language":"PHP","readme":"# PgsqlDoctrineRandomFunction\n\nPostgreSQL RANDOM() function for Doctrine ORM\n\n[![Latest Stable Version](https://poser.pugx.org/qbbr/pgsql-doctrine-random-function/v/stable)](https://packagist.org/packages/qbbr/pgsql-doctrine-random-function)\n[![Total Downloads](https://poser.pugx.org/qbbr/pgsql-doctrine-random-function/downloads)](https://packagist.org/packages/qbbr/pgsql-doctrine-random-function)\n[![License](https://poser.pugx.org/qbbr/pgsql-doctrine-random-function/license)](https://packagist.org/packages/qbbr/pgsql-doctrine-random-function)\n\n## Installation\n\n### Step 1: Download the package\n\n```bash\n$ composer require qbbr/pgsql-doctrine-random-function\n```\n\n### Step 2: Configuration\n\n```yaml\n# app/config/config.yml\n\ndoctrine:\n    orm:\n        # ...\n        dql:\n            numeric_functions:\n                Random: Qbbr\\PgsqlDoctrineRandomFunction\\DQL\\RandomFunction\n```\n\n## Usage\n\n```php\n$em = $this-\u003egetDoctrine()-\u003egetManager();\n\n$result = $em-\u003ecreateQueryBuilder()\n    -\u003eselect('e')\n    -\u003efrom('AppBundle:Entity', 'e')\n    -\u003eorderBy('RANDOM()')\n    -\u003esetMaxResults(10)\n    -\u003egetQuery()\n    -\u003egetResult();\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqbbr%2Fpgsqldoctrinerandomfunction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqbbr%2Fpgsqldoctrinerandomfunction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqbbr%2Fpgsqldoctrinerandomfunction/lists"}