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

[BR-10]-An Invoice shall have the Sum of Invoice line net amount. #26

Closed
seppbrathansel opened this issue Jan 19, 2017 · 6 comments
Closed

Comments

@seppbrathansel
Copy link

This is just one example for an invalid check which as I understood still refers back to an issue with the System function current#0 in EDIFACT\EN16931-EDIFACT-model.sch.

Problem:
When currently checking the EDIFACT_Examples as provided in the instance folders, then e.g. in Example 1 I get this issue:

  <error xsi:type="BAR">
     <description>[BR-10]-An Invoice shall have the Sum of Invoice line net amount.</description>
     <location>xml:1210:0</location>
     <test>G_SG28/S_MOA/C_C516[D_5025='79']/D_5004</test>
  </error>

1.) I get it 6 times - I think 1 would be sufficient?
2.) the amount is there - so why this is an error?
in EDIFACT: MOA+79:229.6
in XML transformation: <G_SG52>
<S_MOA>
<C_C516>
<D_5025>79</D_5025>
<D_5004>229.6</D_5004>
</C_C516>
</S_MOA>
</G_SG52>

@seppbrathansel
Copy link
Author

An amendment:
as I get similar issues within this file, see below.
Maybe the Segmentgroup referred to in the schematron file which seems not correct is the reason?

  <error xsi:type="BAR">
     <description>[BR-13]-An Invoice shall have the Amount due for payment.</description>
     <location>xml:1234:0</location>
     <test>G_SG28/S_MOA/C_C516[D_5025='9']/D_5004</test>
  </error>

@phax phax added the bug label Jan 19, 2017
@seppbrathansel
Copy link
Author

maybe there is a general mismatch of rules and description of rules in file EN16931-EDIFACT-model.sch?

See these 3 lines - BR-10 above seems to fit to the third line value....

phax added a commit that referenced this issue Jan 23, 2017
@phax
Copy link
Collaborator

phax commented Jan 23, 2017

I changed from current() to . and Example 1 ends up with the following SVRL - unfortunately I'm not an Edifact expert...:

<schematron-output xmlns="http://purl.oclc.org/dsdl/svrl" title="EN16931 model bound to EDIFACT">
    <active-pattern id="EN16931-EDIFACT-Model"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <failed-assert id="BR-CO-02" location="/M_INVOIC" test="((G_SG8[S_PYT/D_4279='1']/S_PAI/C_C534/D_4461 = ('30','57')) and (G_SG2[S_NAD/C_C082/D_3039='PE' or S_NAD/C_C082/D_3039='SE']/S_FII[D_3035='RB']/C_C088/D_3434)) or not(G_SG8[S_PYT/D_4279='1']/S_PAI/C_C534/D_4461 = ('30','57'))" flag="fatal">
        <text>[BR-CO-02]-Account identification shall be
      present if payment means is credit transfer. </text>
    </failed-assert>
    <fired-rule context="/M_INVOIC/G_SG2/S_NAD[D_3035='SE']"/>
    <fired-rule context="/M_INVOIC[not(G_SG7/S_CUX/C_C504[D_6347='6']/D_6345 = G_SG7/S_CUX/C_C504[D_6347='2']/D_6345)]"/>
    <failed-assert id="BR-53" location="/M_INVOIC" test="G_SG52/S_MOA/C_C516[D_5025='2']/D_5004" flag="fatal">
        <text>[BR-53]-If the VAT accounting currency code is
      different than the Invoice currency code, then the Invoice total VAT amount in accounting
      currency shall be provided. </text>
    </failed-assert>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC/G_SG54[S_TAX/D_5283='7' and S_TAX/C_C241/D_5153='VAT']"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC/G_SG54/S_TAX[D_5283='7' and C_C241/D_5153='VAT' and D_5305 = 'S']"/>
    <failed-assert id="BR-S-08" location="/M_INVOIC/G_SG54[0]/S_TAX" test="../S_MOA/C_C516[D_5025='125']/D_5004 =      (     round(     sum(/M_INVOIC/G_SG27[     G_SG35/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305='S' and      G_SG35/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG28/S_MOA/C_C516[D_5025='203']/D_5004      )     *10*10)     div 100     ) + (     round(     sum(     /M_INVOIC/G_SG16[     S_ALC/D_5463='C' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305 = 'S' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG20/S_MOA/C_C516[     D_5025='23'     ]/D_5004     )     *10*10)     div 100)      -      (     round(     sum(     /M_INVOIC/G_SG16[     S_ALC/D_5463='A' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305 = 'S' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG20/S_MOA/C_C516[     D_5025='204'     ]/D_5004     )     *10*10)     div 100)" flag="fatal">
        <text>[BR-S-08]-For each different value of VAT
      category rate (BT-119) where the VAT category code (BT-118) is "Standard rated", the VAT
      category taxable amount (BT-116) in a VAT breakdown (BG-23) shall equal the sum of Invoice
      line net amounts (BT-131) plus the sum of document level charge amounts (BT-99) minus the sum
      of document level allowance amounts (BT-92) where the VAT category code (BT-151, BT-102,
      BT-96) is “Standard rated” and the VAT rate (BT-152, BT-103, BT-96) equals the VAT category
      rate (BT-119). </text>
    </failed-assert>
    <failed-assert id="BR-S-08" location="/M_INVOIC/G_SG54[1]/S_TAX" test="../S_MOA/C_C516[D_5025='125']/D_5004 =      (     round(     sum(/M_INVOIC/G_SG27[     G_SG35/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305='S' and      G_SG35/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG28/S_MOA/C_C516[D_5025='203']/D_5004      )     *10*10)     div 100     ) + (     round(     sum(     /M_INVOIC/G_SG16[     S_ALC/D_5463='C' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305 = 'S' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG20/S_MOA/C_C516[     D_5025='23'     ]/D_5004     )     *10*10)     div 100)      -      (     round(     sum(     /M_INVOIC/G_SG16[     S_ALC/D_5463='A' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/D_5305 = 'S' and     G_SG22/S_TAX[     D_5283='7' and      C_C241/D_5153='VAT'     ]/C_C243/D_5278 =      ./C_C243/D_5278     ]/G_SG20/S_MOA/C_C516[     D_5025='204'     ]/D_5004     )     *10*10)     div 100)" flag="fatal">
        <text>[BR-S-08]-For each different value of VAT
      category rate (BT-119) where the VAT category code (BT-118) is "Standard rated", the VAT
      category taxable amount (BT-116) in a VAT breakdown (BG-23) shall equal the sum of Invoice
      line net amounts (BT-131) plus the sum of document level charge amounts (BT-99) minus the sum
      of document level allowance amounts (BT-92) where the VAT category code (BT-151, BT-102,
      BT-96) is “Standard rated” and the VAT rate (BT-152, BT-103, BT-96) equals the VAT category
      rate (BT-119). </text>
    </failed-assert>
    <fired-rule context="/M_INVOIC/G_SG54/S_TAX[D_5283='7' and C_C241/D_5153='VAT' and D_5305 = 'S']"/>
    <fired-rule context="/M_INVOIC/G_SG54/S_TAX[D_5283='7' and C_C241/D_5153='VAT' and D_5305 = 'S']"/>
    <fired-rule context="/M_INVOIC/G_SG27[G_SG35/S_TAX/D_5305 = 'S']"/>
    <fired-rule context="/M_INVOIC/G_SG27[G_SG35/S_TAX/D_5305 = 'S']"/>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[0]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[1]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[2]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[3]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[4]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[5]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[6]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[7]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[8]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[9]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[10]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[11]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[12]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[13]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[14]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[15]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[16]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[17]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[18]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <failed-assert id="BR-S-05" location="/M_INVOIC/G_SG27[19]" test="C_C243/D_5278 &gt; 0" flag="fatal">
        <text>[BR-S-05]-In an Invoice line where the Invoice
      item VAT category code (BT-151) is "Standard rated" the Invoiced item VAT rate (BT-152) shall
      be greater than 0 (zero). </text>
    </failed-assert>
    <active-pattern id="EN16931-EDIFACT-Syntax"/>
    <fired-rule context="/M_INVOIC/S_UNH"/>
    <fired-rule context="/M_INVOIC/S_UNH"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC/S_BGM"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC"/>
    <fired-rule context="/M_INVOIC/S_FTX"/>
    <fired-rule context="/M_INVOIC/S_FTX"/>
    <fired-rule context="/M_INVOIC/S_FTX"/>
    <fired-rule context="/M_INVOIC/S_FTX"/>
    <fired-rule context="/M_INVOIC/S_FTX"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG1"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG2"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG7"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG8"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG27"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG52"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <fired-rule context="/M_INVOIC/G_SG54"/>
    <active-pattern id="EN16931-Codes"/>
    <fired-rule context="//D_6345" flag="fatal"/>
    <fired-rule context="//D_1153" flag="fatal"/>
    <fired-rule context="//D_4451" flag="fatal"/>
    <fired-rule context="//S_FTX[D_4451='DOC']/C_C107/D_4441" flag="warning"/>
    <fired-rule context="//D_3207" flag="fatal"/>
    <fired-rule context="//D_4461" flag="fatal"/>
    <fired-rule context="//D_5305" flag="fatal"/>
    <fired-rule context="//D_7143" flag="fatal"/>
    <fired-rule context="//D_6411" flag="fatal"/>
</schematron-output>

@phax
Copy link
Collaborator

phax commented Jan 25, 2017

It seems like the EDIFACT Schematron rules are not aligned with the latest EN

@phax
Copy link
Collaborator

phax commented Feb 1, 2017

The Schematron rules present in this GitHub repository https://github.com/CenPC434/validation/tree/master/edifact/schematron have a different error text for BR-10:

[BR-10]-An Invoice shall contain the Buyer postal address.

What is [BR-10] in your error is now [BR-12]

So there are 2 possibilities:

  • The Schematron rules you were using are out of date
  • The Schematron rules in this Github repoistory are out of date

Andreas cross checked the rules in this repo and thinks they are fine - so what ruleset did you use for your test??

@AndreasPvd
Copy link
Contributor

Checked again agains examples and did not get any open errors.

@phax phax added this to the v1.0 milestone Apr 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants