How to set up EdiFabric to use multiple X12 versions

287 Views Asked by At

I've purchased ediFabric and have a question about how to set up a project to use it. The SDK that comes with it has a Rules project with a few Codes, Complex Elements and Segments that are specific to a version of the X12 spec, e.g. 005010. My application uses different different versions based on transaction type. For example, 753 & 856 use 005010 and 810 & 855 use 004010.

Should I have one rules project with different folders for the different versions? Or should I have multiple rules projects with one version per project.

1

There are 1 best solutions below

0
Don Zoeggerle On

You would normally group rules by either version or partner. In case your partners conform to the standard specifications and you didn't have to amend the rules in any way - please split rules by version. The pattern is to have each version in a separate project\assembly. EdiFabric allows only one message per version and type in the same assembly. This way is also neat and easy for you to maintain.

Each rules project will contain the 3 common files, Segments, Complex and Codes and the files for the transactions you will be using. There is no point to add all the files and you can gradually upgrade this whenever you need it. Loading the correct specification dynamically can be achieved by using a factory. Please refer to the X12 SDK for sample code or the documentation here.