/mainframe-cobol-db2:cobol-db2-analysisfrom mainframe-cobol-db2
Analyzes COBOL programs, copybooks, DB2 SQL, CICS, and JCL artifacts to map structural relationships and report behavior for legacy system modernization.
Ships in mainframe-cobol-db2. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Read COBOL, DB2, and JCL artifacts as legacy evidence, map their structural relationships, and report behavior without inventing domain meaning.
| Construct | Analyze for |
|---|---|
IDENTIFICATION and ENVIRONMENT DIVISION | Program identity, SELECT clauses, file assignments, and organization. |
DATA DIVISION sections | Record layouts, WORKING-STORAGE, LINKAGE, FILE SECTION, and initial values. |
COPY and REPLACING | Compile-time inclusion, and text substitution that changes the effective layout. |
CALL literal or identifier | Static and dynamic subprogram calls; a dynamic CALL by variable is an unresolved edge. |
PERFORM, PERFORM THRU, GO TO | Internal flow, paragraph ranges, and fall-through that a range hides. |
OPEN, READ, WRITE, REWRITE, DELETE, START | File access mode, key use, and record-not-found handling. |
EXEC SQL blocks | Statement type, tables, columns, host variables, cursors, and SQLCODE handling. |
DECLARE CURSOR, FETCH, CLOSE | Result-set scope, ordering, updatability, and cursor lifetime. |
EXEC CICS blocks | Screen, queue, and transaction boundaries that batch logic does not show. |
PIC, COMP, COMP-3, USAGE | Storage form, precision, sign handling, and truncation behavior. |
OCCURS, OCCURS DEPENDING ON, REDEFINES | Repeating groups, variable-length records, and overlaid storage interpretations. |
| DB2 DDL and DCLGEN | Table and column definition, nullability, keys, indexes, and generated host structures. |
JCL EXEC, DD, PROC | Runtime entry points, step ordering, datasets, dispositions, and external dependencies. |
COBOL dialects and preprocessor conventions vary by site. Infer behavior from repository evidence and the installed compiler options, not from a filename or a dialect assumption.
DATA DIVISION and copybooks before the PROCEDURE DIVISION so layouts and precision are known.CALL, COPY, DD name, cursor, table, and JCL step reachable from the scope.SQLCODE
paths, abends, and error handling with source citations.COMP-3 packed and zoned display numerics carry explicit precision and sign. Do not map monetary or
quantity fields to binary floating point.OCCURS DEPENDING ON makes record length data-dependent. Preserve the controlling field and the actual
occurrence count; a fixed maximum is not the same as the stored value.REDEFINES means one storage area has multiple interpretations. The active interpretation is decided by
program logic, not by declaration order.PERFORM A THRU B range executes every paragraph between the two. Reordering paragraphs changes behavior.SQLCODE +100 is a normal not-found result, not an error. Treat missing SQLCODE checks as a finding.ORDER BY has no guaranteed order even when the legacy output appears ordered.## COBOL/DB2 analysis
**Status:** complete | partial | blocked
**Scope:** <programs, copybooks, DDL, or directory>
### Inventory
| Artifact | Type | Purpose hypothesis | Evidence |
| --- | --- | --- | --- |
### Dependencies
| Source | Relationship | Target | Evidence |
| --- | --- | --- | --- |
### Observed behavior
- <fact with source citation>
### Mismatches and open questions
- <finding or unresolved meaning>
### Validation
- Legacy files modified: no
- Commands run: <commands or none>
OCCURS DEPENDING ON, REDEFINES, and PERFORM THRU semantics are stated rather than assumed.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub gbb-acelerators/awesome-harness-primitives --plugin mainframe-cobol-db215 skills in this plugin
/cobol-db2-contextSupply COBOL, DB2, VSAM, and JCL modernization context: corpus layout, member conventions, target stack boundaries, evidence precedence, stage flow, and security rules. Use when starting any COBOL/DB2 modernization task, before analysis, design, implementation, verification, or delivery./cobol-db2-loopRun each COBOL/DB2 modernization phase as a bounded correction loop with observable exit gates, an iteration ledger, upstream defect escalation, and an engineering graph extracted from COBOL, copybooks, JCL, and DB2 DDL. Use when opening or closing a COBOL/DB2 phase loop, deciding whether a gate passes, routing a defect to the phase that owns its root cause, or building and querying the modernization graph./cobol-legacyOther plugins' skills for the same job