{"id":37901252,"url":"https://github.com/starfishs/sql2struct","last_synced_at":"2026-01-16T17:04:39.867Z","repository":{"id":61628028,"uuid":"548199683","full_name":"starfishs/sql2struct","owner":"starfishs","description":"sql2struct is a tool for sql statement to golang struct","archived":false,"fork":false,"pushed_at":"2025-06-04T10:15:55.000Z","size":361,"stargazers_count":11,"open_issues_count":1,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-06-04T17:51:53.486Z","etag":null,"topics":["go","golang","gorm","model","mysql","postgresql","sql","sql2struct","struct","tool","xorm"],"latest_commit_sha":null,"homepage":"","language":"Go","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/starfishs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null},"funding":{"github":null,"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":null}},"created_at":"2022-10-09T04:55:33.000Z","updated_at":"2025-06-04T10:15:57.000Z","dependencies_parsed_at":"2023-01-23T13:01:37.368Z","dependency_job_id":"d4c69bf2-689c-4ebf-abc1-69e0f1b169d7","html_url":"https://github.com/starfishs/sql2struct","commit_stats":null,"previous_names":["gangming/sql2struct"],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/starfishs/sql2struct","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/starfishs%2Fsql2struct","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/starfishs%2Fsql2struct/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/starfishs%2Fsql2struct/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/starfishs%2Fsql2struct/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/starfishs","download_url":"https://codeload.github.com/starfishs/sql2struct/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/starfishs%2Fsql2struct/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28480081,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["go","golang","gorm","model","mysql","postgresql","sql","sql2struct","struct","tool","xorm"],"created_at":"2026-01-16T17:04:37.443Z","updated_at":"2026-01-16T17:04:39.858Z","avatar_url":"https://github.com/starfishs.png","language":"Go","readme":"[![Build Status](https://travis-ci.org/starfishs/sql2struct.svg?branch=main)](https://travis-ci.org/starfishs/sql2struct)\n[![Go Report Card](https://goreportcard.com/badge/github.com/starfishs/sql2struct)](https://goreportcard.com/report/github.com/starfishs/sql2struct)\n[![GoDoc](https://godoc.org/github.com/starfishs/sql2struct?status.svg)](https://godoc.org/github.com/starfishs/sql2struct)\n[![codecov](https://codecov.io/gh/starfishs/sql2struct/branch/main/graph/badge.svg)](https://codecov.io/gh/starfishs/sql2struct)\n![License](https://img.shields.io/badge/license-GPL-blue.svg)\n# sql2struct\nmysql/postgresql database to golang struct for gorm model\n\n# install\n```shell\ngo install github.com/starfishs/sql2struct@latest\n```\n\n\n\n# usage\n```shell\nsql2struct --dsn=\"mysql://root:123456@tcp(localhost:3306)/test?charset=utf8mb4\"\n```\n# docker\n```shell\ndocker run  -v /path/to/store:/workspace -w /workspace  starfishsfive/sql2struct:v1.0.0 --dsn=\"postgresql://root:123456@localhost:5432/test?sslmode=disable\"\n```\n\n#  support\n- [x] mysql\n- [x] postgreSQL\n\n\n## Contributors\n\n\u003c!-- readme: contributors -start --\u003e\n\u003ctable\u003e\n\u003ctr\u003e\n    \u003ctd align=\"center\"\u003e\n        \u003ca href=\"https://github.com/starfishs\"\u003e\n            \u003cimg src=\"https://avatars.githubusercontent.com/u/15102743?v=4\" width=\"100;\" alt=\"starfishs\"/\u003e\n            \u003cbr /\u003e\n            \u003csub\u003e\u003cb\u003eStarfish\u003c/b\u003e\u003c/sub\u003e\n        \u003c/a\u003e\n    \u003c/td\u003e\n    \u003ctd align=\"center\"\u003e\n        \u003ca href=\"https://github.com/Siqitango\"\u003e\n            \u003cimg src=\"https://avatars.githubusercontent.com/u/165168988?v=4\" width=\"100;\" alt=\"Siqitango\"/\u003e\n            \u003cbr /\u003e\n            \u003csub\u003e\u003cb\u003eNull\u003c/b\u003e\u003c/sub\u003e\n        \u003c/a\u003e\n    \u003c/td\u003e\n    \u003ctd align=\"center\"\u003e\n        \u003ca href=\"https://github.com/miajio\"\u003e\n            \u003cimg src=\"https://avatars.githubusercontent.com/u/22339709?v=4\" width=\"100;\" alt=\"miajio\"/\u003e\n            \u003cbr /\u003e\n            \u003csub\u003e\u003cb\u003eSnaro Chris Xiao\u003c/b\u003e\u003c/sub\u003e\n        \u003c/a\u003e\n    \u003c/td\u003e\n    \u003ctd align=\"center\"\u003e\n        \u003ca href=\"https://github.com/calabashbrother\"\u003e\n            \u003cimg src=\"https://avatars.githubusercontent.com/u/29141309?v=4\" width=\"100;\" alt=\"calabashbrother\"/\u003e\n            \u003cbr /\u003e\n            \u003csub\u003e\u003cb\u003eNull\u003c/b\u003e\u003c/sub\u003e\n        \u003c/a\u003e\n    \u003c/td\u003e\u003c/tr\u003e\n\u003c/table\u003e\n\u003c!-- readme: contributors -end --\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstarfishs%2Fsql2struct","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstarfishs%2Fsql2struct","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstarfishs%2Fsql2struct/lists"}