supplier_invoices
In short
Invoices received by the company managed on Pennylane from its suppliers.
This table is suited for incremental ingestion with an ETL tool. For standard data analysis, use schema
pennylane.
Supplier invoices are imported into Pennylane through various channels (emails, Google Drive, Dropbox, integrations, etc).
In case of simple PDF documents or images, invoices are first read by Pennylane’s OCR, and then manually validated by the user. This means that very recent invoices, not yet validated, may sometimes lack some information or hold errors in their data. For e-invoices or invoices edited on Pennylane, data is directly extracted in a reliable way.
Invoices archived on Pennylane will not be included in this table.
See also: customer_invoices.
Filter key(s)
company_id
Sorting key
ClickHouse skips blocks only when the filter starts with this key, in this order. When the first column is `company_id`, put `company_id` in every query. Read a fleet one company at a time, or in batches of `company_id`. Do not run one query with no company filter. List only the columns you need. `SELECT *` reads columns you will not use.
company_id, id
Available columns
id
Int64
Unique identifier of the invoice on Pennylane.
created_date
Date
Date of creation of the invoice on Pennylane, in YYYY-MM-DD format. This date is not necessarily the same as the invoice issue date.
issue_date
Nullable(Date)
Issue date of the invoice, in YYYY-MM-DD format. In rare situations, an invoice may be received late after the books for the associated fiscal period are closed. In this case, the issue date will default to the first day of the next open fiscal period.
deadline
Nullable(Date)
Invoice due date, in YYYY-MM-DD format.
company_id
Int64
Unique ID of the company on Pennylane, referring to companies.id.
company_name
String
Name of the company on Pennylane.
supplier_id
Nullable(Int64)
Unique ID of the supplier on Pennylane, referring to suppliers.id.
supplier_name
Nullable(String)
Name of the company's supplier, as configured on Pennylane. This name may differ slightly from the one displayed on the invoice.
amount_eur
Decimal(15, 2)
Total invoice amount in euros, including taxes. Potential currency conversions are applied when this field is filled.
amount_eur_excl_taxes
Decimal(18, 2)
Total invoice amount in euros, excluding taxes. Potential currency conversions are applied when this field is filled.
currency
LowCardinality(String)
Invoice currency.
Examples: "EUR", "USD", "CAD"
label
Nullable(String)
Label of the invoice, as displayed on Pennylane.
Examples: "Facture EDF - F-2023-11-123", "Avoir XYZ - F-2022-06-426"
invoice_number
String
Invoice number, as specified on the invoice. This number is unique for any given supplier.
In the present case of supplier invoices, it means this number is unique for a given supplier_id, but the same numbers could be used by different suppliers.
Examples: "F-2023-05-118", "F-2022-06-426"
source
Nullable(String)
Import source of the invoice on Pennylane.
Examples: "Email", "Google Drive", "Dropbox", "FEC"
is_paid
Bool
true the invoice has already been reconciled with its payment.
false otherwise.
An invoice can be set as paid automatically in the following cases:
- when the payment is made via the Pro Account, Qonto or an SEPA XML file export ;
- when a payment is scheduled.
group_uuid
Nullable(UUID)
Identifier of the group this record was matched into.
payment_method
LowCardinality(String)
Payment method.
invoice_kind
LowCardinality(String)
Kind of supplier invoice.
currency_amount
Decimal(17, 4)
Amount in the document currency.
external_id
String
Identifier of the record in the source system.
fec_pieceref
String
Piece reference used in the FEC export.
iban
Nullable(String)
IBAN used for the payment.
paid_at
Nullable(DateTime64(6, 'UTC'))
Time the invoice was marked as paid.
created_at
DateTime64(6, 'UTC')
Timestamp of creation of the invoice on Pennylane.
updated_at
DateTime64(6, 'UTC')
Timestamp of last update of the invoice on Pennylane.
synchronized_at
DateTime64(6, 'UTC')
Timestamp of the last time this row version was written in ClickHouse.
deleted_at
Nullable(DateTime64(6, 'UTC'))
When the record was deleted. Empty when the record is still live. A row dropped by a company-level filter (draft, archived, unknown or deleted company) disappears with no deleted_at. Cascade those from etl.companies.