Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X12 #109

Closed
homer8173 opened this issue Mar 10, 2021 · 6 comments
Closed

X12 #109

homer8173 opened this issue Mar 10, 2021 · 6 comments

Comments

@homer8173
Copy link
Contributor

Hello
i know i m out of context
but one of my prospect want to talk with US in X12 and all my software are done in PHP-EDIFACT
Do you know an easy way to proceed ?
BR,
Norbert

@sabas
Copy link
Collaborator

sabas commented Mar 10, 2021

Hi, there are different people who asked over the years for x12 but I never used it as I don't talk with US partners :)
From my understanding you need to change the separators but the logic should be the same.
UN/EDIFACT is open for specifications, X12 not...
Do you need to parse existing messages or encode or both?
First we need to improve Parser.php and Encoder.php so that they can work with X12.

@homer8173
Copy link
Contributor Author

homer8173 commented Mar 10, 2021

Thanks for you interest, I have a full set to exchange, orders, modifications, invoices and desadv
There is more or less 50% of my software to adapt

@sabas
Copy link
Collaborator

sabas commented Mar 10, 2021

I read this
https://support.edifabric.com/hc/en-us/articles/360000291391-EDI-Basics

For example to split data I tried changing with this function (but apparently in X12 there's no equivalent of the release character ? so I put |).
$c->analyseUNA('>*.| ~');
It would need to change also the parse function for the group separators... (ST instead of UNH for example)

@homer8173
Copy link
Contributor Author

I'm not sure to have the project because I'm far from the result.
An option is to use a translator but it will be expensive

@sabas
Copy link
Collaborator

sabas commented Mar 10, 2021

My suggestion without knowing the usage in your application is to try and make a drop-in replacement for the functions, perhaps it will get easier.
For the "translation" in Intepreter.php where I use the xmls it gets tricky because there's no vocabulary to convert.. :|
At least the message splitting should work by changing the segment names.
The simple conversion between EDI and array should be simple I think.

@homer8173
Copy link
Contributor Author

I gave to this prospect our situation and I'm waiting for their response but yes it seems doable to read those messages

@sabas sabas closed this as completed Aug 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants