# UBL-SR-07

Source: https://xmlvalid.com/rules/UBL-SR-07

> If there is a preceding invoice reference, the preceding invoice number shall be present

- Level: error
- Rule sets: EN 16931 rules (UBL) 1.3.17, EN 16931 rules 1.3.16 (UBL), Romanian RO e-Factura rules (UBL) 1.0.9
- Context: `cac:BillingReference`
- Test: `(cac:InvoiceDocumentReference/cbc:ID)`

> If there is a preceding invoice reference, the preceding invoice number shall be present

- Level: error
- Rule sets: EXTENDED-CTC-FR rules (UBL) 1.4.0.04
- Context: `(/ubl:Invoice|/cn:CreditNote)/cac:BillingReference`
- Test: `(cac:InvoiceDocumentReference/cbc:ID)`

Validate a document against these rules: https://xmlvalid.com/validate
