How the export works
With the SG Finans export, Project Flow creates files with your finalized invoices and credit notes, and the customers on them, in SG Finans' fixed-width factoring format. You send the files to SG Finans, by download, e-mail or FTP. It is a file export, not a live connection.
- Two files per export:
FAKTURA.sgfwith the invoices and credit notes, andKUNDE.sgkwith the customers (debtors) on them. - One direction. Nothing comes back from SG Finans, neither payments nor status.
- No PDF. The invoice PDF and EHF aren't included. Send the invoices to your customers as usual.
Set up the export
Step 1: Add the integration
- Go to Setup → Settings → Integrations (Oppsett → Innstillinger → Integrasjoner) and switch to the tab Export to file (Eksport til fil). You need administrator access.
- Click + Create integration and choose SG Finans.
- Fill in the fields below, tick Enabled and save.
Project Flow plan. The export isn't available on the Start plan. If it has a monthly cost, the form shows it.
Step 2: SG Finans settings
| Field (EN / NB) | Description |
|---|---|
| Customer number / Kundenummer | Your customer number at SG Finans, which you get from them. At most 4 digits. Required. |
Only 4 digits. Project Flow lets you type more, but only the first 4 digits are used in the files. Shorter numbers are filled with leading zeros, for example
65becomes0065.
Step 3: How and when the files are sent
| Field (EN / NB) | Description |
|---|---|
| Default invoice issue date limit / Standard sluttdato for fakturaeksport | Which invoices are included, by invoice date: Up to and including last day of previous month, Current date, or No limitations on date (everything that hasn't been exported yet) (default). |
| Send data to / Send data til | Download folder (default), Email, FTP / FTPS (also SFTP) or HTTP / HTTPS. |
| Transfer files | Only for FTP and HTTP. Manually (default), or Continuously (after each invoice finalization). |
| Define access / Definer tilgang | Only for manual transfer. Limit who may run the export, by access role or coworker. |
Same file names every time. The files are always called FAKTURA.sgf and KUNDE.sgk. With FTP, a new export replaces the files from the last one in the folder, so make sure SG Finans has picked them up first.
Step 4: Prepare Project Flow
- Numbers fit the fields. Customer numbers can have at most 9 digits and invoice numbers at most 8. Longer numbers are cut.
- Customers: SG Finans requires an organization number, an address (first address line, postal code and place) and a country for each debtor. Project Flow doesn't check this, so fill them in on the customers.
- Customer name: according to SG Finans, the company name can't start with AS or similar.
- Short texts. The invoice text is cut to 25 characters and the order reference to 15.
Run the export
- When there are invoices to export, Export to accounting (N) (Eksport til regnskap) appears in the notifications menu (the bell). You need permission to edit invoices, and must be on the access list if one is defined.
- Click it, check the invoices to be exported, and choose a To date if your date limit allows it.
- Click Export. You get links to both files. With Download folder, they are downloaded right away.
- What is included: finalized invoices and credit notes that haven't been exported yet, up to the date you choose.
- Customers: the customers of the exported invoices are written to
KUNDE.sgkin every export, also if they were sent before. - After the export: the invoices get the export status Has been transferred.
- Export again: in the invoice overview, open the cog menu, choose Edit export status (Rediger eksportstatus), set the invoices back to To transfer, and run the export again.
- Earlier files: in the invoice overview, open the cog menu and choose Exported files (Eksporterte filer).
- Continuous transfer: with FTP or HTTP and Continuously, each invoice is sent when it is finalized, and the menu item doesn't appear.
The files
- Fixed width: each field has a fixed position and length, without separators or a header row. One line per invoice or customer, with Windows line breaks.
- Encoding UTF-8.
- Dates as
YYMMDD. - Amounts in øre, without decimal separator or sign, for example
00000618000= 6,180.00. - Numbers are filled with leading zeros, texts with trailing spaces. Too long values are cut.
FAKTURA.sgf (invoices)
| Field | Position | Length | Content |
|---|---|---|---|
| F1 Transaction code | 1 | 1 | 1 invoice, 9 credit note |
| F2 Customer no. | 2–5 | 4 | The Customer number from the integration |
| F3 Debtor no. | 6–14 | 9 | Customer number in Project Flow |
| F4 Invoice no. | 15–22 | 8 | Invoice or credit note number |
| F5 Invoice date | 23–28 | 6 | Invoice date |
| F6 Due date | 29–34 | 6 | Due date |
| F7 Amount | 35–45 | 11 | Total including VAT, after rounding, in your company currency |
| F8 Reference to invoice | 46–53 | 8 | Credit notes: the number of the credited invoice. Invoices: empty (no discount terms) |
| F9 Not in use | 54–58 | 5 | Empty |
| F10 Order no. | 59–73 | 15 | The invoice's order reference |
| F11 Comment | 74–98 | 25 | The invoice text |
| F12 Sales person no. | 99–102 | 4 | The first 4 letters of your contact person's name on the invoice |
| F13 Project no. | 103–109 | 7 | Project number |
| F14 Currency code | 110–112 | 3 | Invoice currency, for example NOK or EUR |
| F15 Currency amount | 113–123 | 11 | Total in the invoice currency |
Not in the file: KID, VAT, invoice lines and accounts.
KUNDE.sgk (customers)
| Field | Length | Content |
|---|---|---|
| K1 Control character | 1 | K |
| K2 Version number | 4 | 9409 |
| K3 Customer no. | 4 | The Customer number from the integration |
| K4 Debtor no. | 9 | Customer number in Project Flow |
| K5 Organization no. | 11 | The customer's organization number |
| K6 Company name | 35 | Customer name |
| K7 First name | 20 | Empty |
| K8 Address | 30 | First address line |
| K9 Zip code | 4 | Postal code |
| K10 Post place | 23 | Postal place |
| K11 Contact person | 20 | Empty |
| K12 Telephone no. | 12 | Customer phone |
| K13 Country | 20 | Country name in English, for example Norway |
| K14 / K15 Country code | 2 + 3 | Country code as letters (NO) and number (578) |
| K16 Bank giro number | 11 | The customer's bank account number |
| K17, K18 | 4 + 35 | Empty |
| K19 Currency code | 3 | The customer's currency, or your company currency |
The address is the customer's main address. If it has none, the invoice address, then the visiting address, is used.
Q&A
Q: "There are no invoices to export in the specified period."
A: All finalized invoices up to the date are already exported. Choose a later date, or set invoices back to To transfer with Edit export status.
Q: SG Finans says our customer number in the file is wrong.
A: Check the Customer number in the integration. Only the first 4 digits are used.
Q: SG Finans can't read a line, or the fields are shifted.
A: Check the customer and invoice on that line: customer number at most 9 digits, invoice number at most 8, and a postal code with 4 digits. Contact Project Flow support with the invoice number if it still fails.
Q: The KID isn't in the file.
A: No, the SG Finans format from Project Flow doesn't include KID.
Q: Why are the same customers in every file?
A: Project Flow always includes the customers of the exported invoices, also if they were sent before.
Q: I need to send an invoice again.
A: Set its export status back to To transfer with Edit export status, and run the export again. Or download the earlier files from Exported files.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article