{
  "id": "go/database-sql-rows-scan-type-mismatch",
  "signature": "error: sql: Scan error on column index 0: unsupported Scan, storing driver.Value type int64 into type *string",
  "signature_zh": "错误：sql：列索引0上的扫描错误：不支持的扫描，将driver.Value类型int64存储到*string类型",
  "regex": "error:\\ sql:\\ Scan\\ error\\ on\\ column\\ index\\ 0:\\ unsupported\\ Scan,\\ storing\\ driver\\.Value\\ type\\ int64\\ into\\ type\\ \\*string",
  "domain": "go",
  "category": "type_error",
  "subcategory": null,
  "root_cause": "Scanning a database column into a Go variable of incompatible type, e.g., scanning an integer into a string pointer.",
  "root_cause_type": "generic",
  "root_cause_zh": "将数据库列扫描到不兼容类型的Go变量中，例如将整数扫描到字符串指针。",
  "versions": [
    {
      "version": "1.20",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "1.21",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "Using fmt.Sprintf to convert values manually",
      "why_fails": "Inefficient and error-prone; use proper type mapping.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Use sql.NullString or appropriate types",
      "success_rate": 0.9,
      "how": "var name sql.NullString\nif err := rows.Scan(&name); err != nil { return err }\nif name.Valid { /* use name.String */ }",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": null,
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.87,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2025-02-20",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}