Cross-Format EDI, JSON, and XML File Comparison
File comparison helps integration teams check whether a converted or downstream file still contains the meaningful values from a trusted source file. The source and target can be different formats, so you can compare EDI to JSON, EDI to XML, XML to JSON, JSON to XML, or same-format files in one browser-local workflow.
Breadcrumbs: Home / Compare overview
What cross-format comparison finds
A useful comparison should make the important differences obvious without forcing the user to scan every character manually. USA Data Tools checks the source file first, then looks for evidence in the target file even when the target uses a different format or different paths.
- EDI segment values that should appear somewhere in a JSON or XML conversion
- XML text or attributes that should appear in a JSON target
- JSON scalar values that should appear in an XML or EDI-style target
- Missing source values that do not appear in the target file
- Matched values found under different JSON, XML, or EDI paths
- Possible mismatches such as
ABC-123versusABC123 - Date and number formatting differences that match only after normalization
- Ignored EDI control values when envelope checking is turned off
Two validation phases
The comparison report runs in two phases. First, it checks structure and loops. JSON arrays, repeated XML sibling elements, and repeated EDI business segments are treated as repeated groups. The tool uses available values inside each group as anchors and reports strong, weak, or missing evidence in the target, regardless of whether the target is JSON, XML, or EDI.
Second, it checks values. Every meaningful source value is normalized and searched in the target. Exact matches, normalized matches, possible mismatches, missing values, ignored values, warnings, and errors are shown in separate report sections.
Why browser-local comparison helps
EDI, JSON, and XML payloads can contain partner IDs, customer references, item data, addresses, or other sensitive business values. The compare tool reads files with browser-native file APIs and keeps the contents in memory for the current page session.
File contents, extracted values, report data, and error details are not uploaded to a backend API, external API, analytics service, monitoring service, database, queue, or storage bucket.
How USA Data Tools supports comparison work
The compare workspace accepts pasted payloads, user-selected files, dropped files, and local path setup values. It detects JSON, XML, and EDI locally, shows source and target file metadata, and generates a local cross-format report with structure validation, compared values, and missing values.
Reports can be downloaded locally as JSON or HTML, and missing values can be downloaded or copied as CSV. Large comparisons are capped with visible warnings so the browser remains responsive.
Before and after example
Before: source value ABC-123 in EDI or XML.
After: target value ABC123 in JSON or a downstream feed.
What this is good for: proving the same business value survived conversion while the browser kept the work local.
When to use the line and hex views
The value report is best for checking whether source business values made it into the target. The line view and hex view are still useful when two files look similar as structured data but behave differently because of hidden control characters, delimiters, encoding surprises, or line ending differences such as 0D 0A versus 0A.