{
  "schema": 1,
  "sqlstate": "22033",
  "condition_name": "invalid_sql_json_subscript",
  "sources": [
    {
      "id": "src.errcodes.18.6",
      "kind": "upstream_source",
      "source_role": "condition_definition",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/errcodes.txt",
      "sha256": "6e8de346643ba84aa3c9c6a73360acfc7b2dfb89162c06c08ce9bf5bcd5bbcba",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/errcodes.txt#L218",
      "lines": "218"
    },
    {
      "id": "src.path.0",
      "kind": "upstream_source",
      "source_role": "resolved_report_context",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/adt/jsonpath_exec.c",
      "sha256": "678cb8947f0b5e6ad14524f1863987ab99641cfb5f81121fc5c5006af0319d02",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/adt/jsonpath_exec.c#L919",
      "lines": "919-921"
    },
    {
      "id": "src.jsonpath.subscript",
      "kind": "upstream_source",
      "source_role": "resolved_report_context",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/adt/jsonpath_exec.c",
      "sha256": "678cb8947f0b5e6ad14524f1863987ab99641cfb5f81121fc5c5006af0319d02",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/adt/jsonpath_exec.c#L3442",
      "lines": "3442-3477"
    }
  ],
  "claims": [
    {
      "id": "identity",
      "statement": "22033 is invalid_sql_json_subscript in SQLSTATE Class 22.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Read fixed definition."
    },
    {
      "id": "resolved-path",
      "statement": "The fixed jsonpath executor evaluates each subscript to one numeric item, truncates it to int32, and raises 22033 for a non-single numeric result or integer-range overflow; strict mode also raises for invalid array bounds, while lax mode ignores structural out-of-bounds errors and clamps the range.",
      "sources": [
        "src.path.0",
        "src.jsonpath.subscript"
      ],
      "method": "Read the complete array-subscript execution and getArrayIndex conversion guards.",
      "limits": "Source confirmation is not a natural runtime observation."
    },
    {
      "id": "history",
      "statement": "The locked catalogue records 22033 from 12.0 without proving exact implementation introduction.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Use catalogue boundary."
    }
  ],
  "messages": [
    {
      "id": "message.0",
      "sqlstate": "22033",
      "primary_template": "jsonpath array subscript is out of bounds",
      "severity_source": "ERROR",
      "sources": [
        "src.path.0"
      ]
    },
    {
      "id": "message.non-single-numeric",
      "sqlstate": "22033",
      "primary_template": "jsonpath array subscript is not a single numeric value",
      "severity_source": "ERROR",
      "sources": [
        "src.jsonpath.subscript"
      ]
    },
    {
      "id": "message.integer-range",
      "sqlstate": "22033",
      "primary_template": "jsonpath array subscript is out of integer range",
      "severity_source": "ERROR",
      "sources": [
        "src.jsonpath.subscript"
      ]
    }
  ],
  "usage_evidence": [
    {
      "scope": "definition",
      "status": "definition_only",
      "evidence_ids": [
        "identity"
      ]
    },
    {
      "scope": "fixed-source-path",
      "status": "source_path_confirmed",
      "evidence_ids": [
        "resolved-path"
      ]
    },
    {
      "scope": "history",
      "status": "unknown",
      "evidence_ids": [
        "history"
      ]
    },
    {
      "scope": "natural-runtime",
      "status": "unknown",
      "evidence_ids": [
        "resolved-path"
      ]
    }
  ],
  "runtime": []
}
