{"id":19694577,"url":"https://github.com/vaneves/java-query-builder","last_synced_at":"2026-05-15T04:05:14.082Z","repository":{"id":146044857,"uuid":"149872933","full_name":"vaneves/java-query-builder","owner":"vaneves","description":"☕ Simple library for database with Java","archived":false,"fork":false,"pushed_at":"2018-09-22T15:38:38.000Z","size":6,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-27T12:42:24.791Z","etag":null,"topics":["database","java"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vaneves.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}},"created_at":"2018-09-22T12:00:29.000Z","updated_at":"2020-07-24T17:38:32.000Z","dependencies_parsed_at":null,"dependency_job_id":"602b5a7c-6b33-4acb-a64b-e6bb3f20367b","html_url":"https://github.com/vaneves/java-query-builder","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/vaneves/java-query-builder","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vaneves%2Fjava-query-builder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vaneves%2Fjava-query-builder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vaneves%2Fjava-query-builder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vaneves%2Fjava-query-builder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vaneves","download_url":"https://codeload.github.com/vaneves/java-query-builder/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vaneves%2Fjava-query-builder/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33053153,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"online","status_checked_at":"2026-05-15T02:00:06.351Z","response_time":103,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["database","java"],"created_at":"2024-11-11T19:23:36.637Z","updated_at":"2026-05-15T04:05:14.054Z","avatar_url":"https://github.com/vaneves.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ☕ Java Query Builder\n\nA simple library for database with Java.\n\n## Examples\n\n\n\n### Insert\n\n```java\nQueryBuilder.insert(\"user\")\n\t.columns(\"id\", \"name\")\n\t.execute(1, \"Van Neves\");\n```\n\n| Method | Params | Return |\n| --- | --- | --- |\n| `insert()` | Table name | `QueryBuilderInsert` |\n| `columns()` | Columns name | `QueryBuilderInsert` |\n| `execute()` | Values | `boolean` |\n\n### Update\n\n```java\nQueryBuilder.update(\"user\")\n\t.set(\"name\", \"?\")\n\t.where(\"id\", \"?\")\n\t.execute(\"Nyl Marcos\", 4);\n```\n\n| Method | Params | Return |\n| --- | --- | --- |\n| `update()` | Table name | `QueryBuilderUpdate` |\n| `set()` | The column and new value  | `QueryBuilderUpdate` |\n| `setSafe()` | The column (the value will be passed in the `execute()` method)  | `QueryBuilderUpdate` |\n| `where()` | Column, comparator and value | `QueryBuilderUpdate` |\n| `whereSafe()` | The column (the value will be passed in the `execute()` method) | `QueryBuilderUpdate` |\n| `execute()` | Values | `boolean` |\n\n### Delete\n\n```java\nQueryBuilder.delete(\"user\")\n\t.where(\"id\", \"\u003e=\", \"?\")\n\t.execute(1);\n```\n\n| Method | Params | Return |\n| --- | --- | --- |\n| `delete()` | Table name | `QueryBuilderDelete` |\n| `where()` | Column, comparator and value | `QueryBuilderDelete` |\n| `whereSafe()` | The column (the value will be passed in the `execute()` method) | `QueryBuilderDelete` |\n| `execute()` | Values | `boolean` |\n\n### List\n\n```java\nArrayList\u003cUser\u003e users = new ArrayList\u003cUser\u003e();\n\nQueryBuilder.select(\"id\", \"name\")\n\t.from(\"user\")\n\t.where(\"id\", \"\u003e\", \"?\")\n\t.orderBy(\"name\")\n\t.execute((rs, cnt)-\u003e {\n\t\tusers.add(new User(rs.getInt(\"id\"), rs.getString(\"name\")));\n\t}, 1);\n```\n\n| Method | Params | Return |\n| --- | --- | --- |\n| `select()` | Columns name | `QueryBuilderSelect` |\n| `from()` | The table name  | `QueryBuilderSelect` |\n| `where()` | Column, comparator and value | `QueryBuilderSelect` |\n| `whereSafe()` | The column (the value will be passed in the `execute()` method) | `QueryBuilderSelect` |\n| `orderBy()` | The column name | `QueryBuilderSelect` |\n| `orderByDesc()` | The column name | `QueryBuilderSelect` |\n| `execute()` | Lambda and values | `void` |\n\n### Get\n\n```java\nUser user;\n\nQueryBuilder.select(\"id\", \"name\")\n\t.from(\"user\")\n\t.where(\"id\", \"=\", \"?\")\n\t.execute((rs, cnt)-\u003e {\n\t\tuser = new User(rs.getInt(\"id\"), rs.getString(\"name\"));\n\t}, 1);\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvaneves%2Fjava-query-builder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvaneves%2Fjava-query-builder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvaneves%2Fjava-query-builder/lists"}