{"id":23176502,"url":"https://github.com/lajosbencz/php-stream-parse-sql","last_synced_at":"2025-04-05T01:23:11.069Z","repository":{"id":57010776,"uuid":"234338573","full_name":"lajosbencz/php-stream-parse-sql","owner":"lajosbencz","description":"PHP library to parse large SQL files command-by-command","archived":false,"fork":false,"pushed_at":"2020-01-20T17:27:05.000Z","size":40,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-10T09:42:07.078Z","etag":null,"topics":["php","sql","streaming-parser"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lajosbencz.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":"2020-01-16T14:30:27.000Z","updated_at":"2020-01-20T17:27:07.000Z","dependencies_parsed_at":"2022-08-21T13:10:18.043Z","dependency_job_id":null,"html_url":"https://github.com/lajosbencz/php-stream-parse-sql","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/lajosbencz%2Fphp-stream-parse-sql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lajosbencz%2Fphp-stream-parse-sql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lajosbencz%2Fphp-stream-parse-sql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lajosbencz%2Fphp-stream-parse-sql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lajosbencz","download_url":"https://codeload.github.com/lajosbencz/php-stream-parse-sql/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247273016,"owners_count":20911853,"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":["php","sql","streaming-parser"],"created_at":"2024-12-18T06:17:03.592Z","updated_at":"2025-04-05T01:23:11.052Z","avatar_url":"https://github.com/lajosbencz.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# php-stream-parse-sql\nPHP library to parse large SQL files command-by-command\n\nIt's not a real SQL parser though, it only cares about command integrity, but not syntax.\n\n### Install:\n\n```\ncomposer require lajosbencz/stream-parse-sql\n```\n\n### Usage:\n\n```php\n$parser = new LajosBencz\\StreamParseSql\\StreamParseSql(\"./my/large/file.sql\");\n$parser-\u003eonProgress(function($position, $size) {\n    echo ($position / $size) * 100, PHP_EOL;\n});\nforeacH($parser-\u003eparse() as $sqlCommand) {\n    /** @var stdClass $myDb some database adapter */\n    $myDb-\u003eexecute($sqlCommand);\n}\n```\n\n### Todo:\n * Extensively test if any input can produce a malformed command\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flajosbencz%2Fphp-stream-parse-sql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flajosbencz%2Fphp-stream-parse-sql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flajosbencz%2Fphp-stream-parse-sql/lists"}