代码之家  ›  专栏  ›  技术社区  ›  Tom Schulte

azure逻辑应用中的edifact delfor解码

  •  1
  • Tom Schulte  · 技术社区  · 6 年前

    我正从x12转向其他格式,使用逻辑应用程序+集成帐户,没有太多edi或la经验。

    下面是我的示例:

    UNB+UNOA:2+OURCODE:ZZ+THEIRCODE:01+180523:1005+157'
    UNG+DELFOR+OURCODE+THEIRCODE+180523:1005+157+UN+D:96A'
    UNH+15700001+DELFOR:D:96A:UN'
    BGM+241+201805231005-1+5'
    DTM+137:20180523:102'
    DTM+323:2018052120180820:711'
    NAD+MI+OURCODE::92'
    NAD+SF+THEIRCODE::92'
    NAD+SU+THEIRCODE::92'
    UNS+D'
    NAD+ST+OURCODE::92'
    LIN+++TESTPARTA1:IN'
    PIA+1+RECEIVERPARTNO:VP'
    RFF+ON:PONUMBER55'
    QTY+1:3080:EA'
    SCC+4++W'
    DTM+2:20180521:102'
    QTY+1:0:EA'
    SCC+4++W'
    DTM+2:20180528:102'
    QTY+1:0:EA'
    SCC+4++W'
    DTM+2:20180604:102'
    QTY+1:880:EA'
    SCC+4++W'
    DTM+2:20180611:102'
    QTY+1:2200:EA'
    SCC+4++W'
    DTM+2:20180618:102'
    QTY+1:1760:EA'
    SCC+4++W'
    DTM+2:20180625:102'
    QTY+1:1760:EA'
    SCC+4++W'
    DTM+2:20180702:102'
    QTY+1:1760:EA'
    SCC+4++W'
    DTM+2:20180709:102'
    QTY+1:1760:EA'
    SCC+4++W'
    DTM+2:20180716:102'
    QTY+1:1320:EA'
    SCC+4++W'
    DTM+2:20180723:102'
    QTY+1:1320:EA'
    SCC+4++W'
    DTM+2:20180730:102'
    QTY+1:440:EA'
    SCC+4++W'
    DTM+2:20180806:102'
    QTY+1:440:EA'
    SCC+4++W'
    DTM+2:20180813:102'
    QTY+1:440:EA'
    SCC+4++W'
    DTM+2:20180820:102'
    QTY+3:274560:C62'
    SCC+2'
    DTM+52:20180604:102'
    QTY+3:275440:C62'
    SCC+3'
    DTM+52:20180611:102'
    QTY+3:271480:C62'
    DTM+50:20180522:102'
    QTY+1:2640:C62'
    DTM+50:20180522:102'
    RFF+AAK:CG07656'
    QTY+79:271480:C62'
    DTM+52:20180522:102'
    UNS+S'
    UNT+69+15700001'
    UNE+1+157'
    UNZ+1+157'
    

    我在用 Liaison EDI Notepad 对其进行一般性验证。它没有报告任何问题,我发现它是一个非常可靠的工具。我对其他验证建议持开放态度。

    现在,对于在la中执行解码edifact操作,我应该使用哪个ms模式?我从中选择了efact_d96a_delfor.xsd MicrosoftEdiXSDTemplates.zip available on GitHub 是的。这是适合我样品的吗?当我尝试该操作时,我有原始输入:

    {
    "host": {
        "connection": {
            "name": "/subscriptions/..."
        }
    },
    "method": "post",
    "path": "/decode",
    "queries": {
        "componentSeparator": "58",
        "dataElementSeparator": "43",
        "decimalIndicator": "Comma",
        "releaseIndicator": "63",
        "repetitionSeparator": "42",
        "segmentTerminator": "39",
        "segmentTerminatorSuffix": "None"
    },
    "body": {
        "$content-type": "application/octet-stream",
        "$content": "VU5CK1VOT0E6MitPVVJDT0RFOlpaK1RIRUlSQ09ERTowMSsxODA1MjM6MTAwNSsxNTcnDQpVTkcrREVMRk9SK09VUkNPREUrVEhFSVJDT0RFKzE4MDUyMzoxMDA1KzE1NytVTitEOjk2QScNClVOSCsxNTcwMDAwMStERUxGT1I6RDo5NkE6VU4nDQpCR00rMjQxKzIwMTgwNTIzMTAwNS0xKzUnDQpEVE0rMTM3OjIwMTgwNTIzOjEwMicNCkRUTSszMjM6MjAxODA1MjEyMDE4MDgyMDo3MTEnDQpOQUQrTUkrT1VSQ09ERTo6OTInDQpOQUQrU0YrVEhFSVJDT0RFOjo5MicNCk5BRCtTVStUSEVJUkNPREU6OjkyJw0KVU5TK0QnDQpOQUQrU1QrT1VSQ09ERTo6OTInDQpMSU4rKytURVNUUEFSVEExOklOJw0KUElBKzErUkVDRUlWRVJQQVJUTk86VlAnDQpSRkYrT046UE9OVU1CRVI1NScNClFUWSsxOjMwODA6RUEnDQpTQ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OjEwMicNClJGRitBQUs6Q0cwNzY1NicNClFUWSs3OToyNzE0ODA6QzYyJw0KRFRNKzUyOjIwMTgwNTIyOjEwMicNClVOUytTJw0KVU5UKzY5KzE1NzAwMDAxJw0KVU5FKzErMTU3Jw0KVU5aKzErMTU3Jw=="
    }
    

    }

    输出中包含一个错误,使我认为我没有正确验证(错误的xsd?)以下内容:

    错误:1(字段级错误) 段ID:UNB 在TS中的位置:1 数据元素ID:UNB3.2 段内位置:4 现场位置:2 数据值:01 12:数据元素中的值无效

    我认为这是指第一段(线)上的01前导01+180523:1005+157,指的是日期时间2018年5月23日10:05。实际上01指的是我的客人身份。这里指出的问题是什么?

    This JPG  是相关的IA协议。

    我正在寻找有关故障排除的建议,包括一般将给定的DelFor或其他Edvices匹配到正确的MSXSD。

    在我做完这些之后,我计划下一步去做视频点播。你有什么建议我记住的吗?

    谢谢你

    link 是的。但是,我改成了zz,这确实导致了另一个错误。输出是

    "badMessages": [
            {
                "UNB": {
                    "UNB_Segment": "UNB+UNOA:2+OURCODE:ZZ+THEIRCODE:ZZ+180523:1005+157'\r\n################",
                    "UNB2.1": "OURCODE",
                    "UNB2.2": "ZZ",
                    "UNB3.1": "THEIRCODE",
                    "UNB3.2": "ZZ"
                },
                "UNG": {
                    "UNG_Segment": "UNG+DELFOR+OURCODE+THEIRCODE+180523:1005+157+UN+D:96A'\r\n",
                    "UNG1": "DELFOR",
                    "UNG2.1": "OURCODE",
                    "UNG3.1": "THEIRCODE",
                    "UNG4.1": "180523",
                    "UNG4.2": "1005",
                    "UNG5": "157",
                    "UNG6": "UN",
                    "UNG7.1": "D",
                    "UNG7.2": "96A"
                },
                "UNH": {
                    "UNH1": "15700001",
                    "UNH2.1": "DELFOR",
                    "UNH2.2": "D",
                    "UNH2.3": "96A",
                    "UNH2.4": "UN"
                }, ...
    

    zz的错误是

    分析期间遇到错误。ID为“157”的功能组中包含的ID为“1570001”的EDIFACT事务集, 在ID为“157”、发送方ID为“ourcode”的交换中,接收器ID为“theircode”被挂起,并出现以下错误: 错误:1(杂项错误)\r\n\t70:\r\n\r\n 错误:2(杂项错误)\r\n\t71:事务集或组控制号不匹配\r\n\r\n 错误:3(杂项错误)\r\n\t29:在交换、组或消息级别指定的计数无效\r\n\r\n“,

    注意,UNT段具有正确的段计数和控制号:UNT+69+1570001'

    在输出中,有效载荷报告无效的模式,包括正确解析的UNH段:

    <UnrecognizedSchema>
    <UnrecognizedSegment>
        UNH+15700001+DELFOR:D:96A:UN
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        BGM+241+201805231005-1+5
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+137:20180523:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+323:2018052120180820:711
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        NAD+MI+OURCODE::92
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        NAD+SF+THEIRCODE::92
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        NAD+SU+THEIRCODE::92
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        UNS+D
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        NAD+ST+OURCODE::92
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        LIN+++TESTPARTA1:IN
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        PIA+1+RECEIVERPARTNO:VP
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        RFF+ON:PONUMBER55
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:3080:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180521:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:0:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180528:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:0:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180604:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:880:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180611:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:2200:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180618:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1760:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180625:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1760:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180702:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1760:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180709:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1760:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180716:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1320:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180723:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:1320:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180730:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:440:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180806:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:440:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180813:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:440:EA
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+4++W
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+2:20180820:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+3:274560:C62
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+2
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+52:20180604:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+3:275440:C62
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        SCC+3
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+52:20180611:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+3:271480:C62
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+50:20180522:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+1:2640:C62
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+50:20180522:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        RFF+AAK:CG07656
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        QTY+79:271480:C62
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        DTM+52:20180522:102
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        UNS+S
    </UnrecognizedSegment>
    <UnrecognizedSegment>
        UNT+42+15700001
    </UnrecognizedSegment>
    

    1 回复  |  直到 6 年前
        1
  •  0
  •   Tom Schulte    6 年前

    感谢所有发表评论的人。

    最后,改变内容不是一种选择,因为我们正在处理各种客户的EDI,而不是生成它。我输入了一个支持请求,ms在其末尾更改了一些内容,我今天对它进行了测试,验证这不再是一个问题,至少在我运行代码的eastus azure区域是这样。