Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreThe FabCon + SQLCon recap series starts April 14th at 8am Pacific. If you’re tracking where AI is going inside Fabric, this first session is a can't miss. Register now
Hello everyone,
I’m currently working on an EDI solution for a client, and this is my first time working with EDI formats. The requirement is to convert PDF invoices into an EDI format that can later be imported into the client’s system, with the goal of reducing manual invoice entry.
So far, I’ve already extracted the structured data from the PDF files using Power BI, but I’m facing challenges with the next step: understanding how to build an EDI conversion tool that can transform this structured data into an EDI .txt file.
I also have the mapping specification template for X12 837, but I’m still trying to understand the best approach, tools, or design patterns for implementing this effectively.
I’d really appreciate any guidance from anyone who has worked on something similar, especially around:
how to design the conversion process
how to generate EDI files correctly
recommended tools, libraries, or best practices
Any advice, examples, or direction would be extremely helpful. Thank you in advance.
A good starting point is this: 837 is usually the wrong transaction set for invoices. In X12, the 837 is the Health Care Claim transaction set, used for submitting healthcare claims to payers, not general invoicing. For invoices, the common X12 transaction is 810 (Invoice), and in some client ecosystems the right answer may instead be EDIFACT INVOIC, Peppol BIS Billing, or a custom flat-file layout. So before you build anything, confirm the client’s required standard, version, and implementation guide.
If the client truly asked for X12 837, pause and verify whether they actually mean a healthcare claim workflow. X12’s own description says 837 is for health care claim billing and encounters, and their examples for 005010X222 are specifically professional healthcare claim examples.
The best design is not “PDF to EDI” directly, but a two-stage pipeline:
A practical architecture looks like this:
That approach is much safer than trying to generate EDI straight out of Power BI transformations.
For the actual file generation, think in terms of segments and envelopes. In X12, you do not just dump rows into a .txt file. You must build the interchange structure correctly, typically including ISA/GS/ST ... SE/GE/IEA, with the transaction’s business segments in the middle. The exact middle content depends on whether you are generating an 810, 837, or something else. The X12 examples are useful for seeing the expected shape of a valid file.
For tools, a dedicated EDI library is usually worth it. In .NET, EdiFabric supports parsing, generating, validating, acknowledgments, and multiple standards including X12; its public examples specifically cover X12 and HIPAA flows. There are also lighter/open-source options like EdiEngine and older packages such as OopFactory.X12, but those may require more manual work and may not be as complete for validation or newer implementations.
Because you mentioned Power BI: Power BI is fine for extracting and shaping data, but it is not the ideal place to author a production-grade EDI generator. Microsoft’s Power BI/Fabric guidance is centered on prep, modeling, export, and orchestration—not EDI serialization. A stronger pattern is:
Best practices that save a lot of pain:
So my honest recommendation is:
If you want, I can sketch a concrete end-to-end design for either PDF → canonical JSON/table → X12 810 or PDF → canonical JSON/table → X12 837, with example segment mapping.
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !!
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |