Table of Contents

Sales / Purchase Journal Import Feature - Setup & Processing Guide

Overview

The Sales / Purchase Journal Import feature in the Linc Third Party Transactions extension enables automatic creation of Business Central General Journal Lines in Sales and Purchase journal batches from imported transaction data. This feature supports account and balancing account handling, posting setup updates, multi-currency processing, and optional dimension mapping for controlled financial journal processing.

Key Components

  • Application Area: Financial
  • Transaction Types: Sales and Purchase
  • Supported Account Types (Main Account): G/L Account, Customer, Vendor, Fixed Asset
  • Supported Balancing Account Types: Bank Account, G/L Account
  • Currency Support: Multi-currency with exchange rate handling
  • Output: Business Central Sales Journal Lines and Purchase Journal Lines
  • Processing Codeunit: ThirdPartySPJnlMgt_THI_LINC (Codeunit 71112714)

Prerequisites

1. Basic Business Central Setup

  • General Ledger Setup configured
  • Chart of Accounts configured
  • Sales journal template and batches configured
  • Purchase journal template and batches configured
  • General Posting Groups and VAT Posting Groups configured (if posting setup values are imported)
  • Bank Accounts configured (if using bank balancing accounts)
  • Currencies configured (if processing foreign currency lines)
  • Dimensions configured (if using imported dimension values)

2. Extension Setup

  • Linc Third Party Transactions extension installed
  • Appropriate user permissions configured
  • Third Party Setup created for each external source
  • Third Party Mappings configured (if using mapping)

Step-by-Step Setup Instructions

Step 1: Configure Third Party Setup for Sales / Purchase Journals

  1. Navigate to Third Party Setup List (Page 71112700)
  2. Create or modify a setup record with the following configuration:

General Settings

  • Third Party Code: Unique identifier for the integration
  • Application Area: Set to Financial
  • XMLPort ID: Select XMLPort when using XML/text/CSV file import
  • No. of Header Rows: Number of header rows to skip for Excel import

Journal Configuration (Journals FastTab)

  • Sales Journal Template: Default template for Sales journal processing
  • Sales Journal Batch: Default batch for Sales journal processing
  • Purchase Journal Template: Default template for Purchase journal processing
  • Purchase Journal Batch: Default batch for Purchase journal processing
  • Use Def. Post. setup Gen Jnl: Use BC account posting setup values automatically
  • Update Posting Setup Trans. Detail: Update posting setup details from imported transaction data
  • Use Default Dimensions: Use account defaults instead of imported dimensions
  • Use Import Description: Use imported Description field on journal lines

Processing Options

  • Use Mapping: Enable account and dimension mapping
  • Attempt Direct Mapping: Attempt direct value resolution when mapping is missing
  • Automatically Validate: Auto-validate imported transactions
  • Automatically Create Trans.: Auto-create journal lines after validation
  • Automatically Post Trans.: Auto-post journal lines after creation

Step 2: Configure Sales and Purchase Journal Templates & Batches

  1. Navigate to General Journal Templates
  2. Set up or verify the Sales journal template:
  • Template Type: Must be Sales
  • Name: Must match Sales Journal Template in Third Party Setup
  • Source Code: Source code used for tracking
  • No. Series: Optional number series for document numbering
  1. Set up or verify the Purchase journal template:
  • Template Type: Must be Purchases
  • Name: Must match Purchase Journal Template in Third Party Setup
  • Source Code: Source code used for tracking
  • No. Series: Optional number series for document numbering
  1. For each template, configure at least one batch:
  • Journal Template Name: Linked to the correct template
  • Name: Must match the corresponding batch in Third Party Setup
  • Bal. Account Type / Bal. Account No.: Optional batch defaults used when not supplied by import
  • No. Series: Number series for document numbers

Step 3: Configure Third Party Mappings (if using mappings)

If Use Mapping is enabled:

  1. Navigate to Third Party Mappings (Page 71112706)
  2. Create mappings as needed:

Main Account Mappings

  • Mapping Type: G/L Account, Customer, Vendor, or Fixed Asset
  • Third Party Reference No.: External account value
  • Mapping No.: Internal BC account number

Balancing Account Mappings

  • Mapping Type: G/L Account (for balancing G/L accounts)
  • Third Party Reference No.: External balancing account value
  • Mapping No.: Internal BC G/L account number

Note: Balancing account type Bank Account is resolved directly against Business Central Bank Accounts.

Dimension and VAT Mapping (optional)

  • Mapping Type: Shortcut Dimension 1 Code through Shortcut Dimension 8 Code
  • Mapping Type: VAT Bus. Posting Group, VAT Prod. Posting Group, and balancing VAT posting groups (if values are imported)

Step 4: Configure Excel Import Mapping (for Excel import)

If importing from Excel files:

  1. Navigate to Third Party Excel Import Mapping (Page 71112709)
  2. Create field mappings:
  • Third Party Code: Same as setup record
  • Mapping Type: Field (column reference) or Fixed Value
  • Third Party Reference No.: Column name or fixed value
  • Third Party Trans. Field ID: Target field in transaction table

Required Data Fields for Sales / Purchase Journals

Mandatory Fields

  • Application Area: Must be Financial
  • Transaction Type: Must be Sales or Purchase
  • Gen. Jnl Account Type: G/L Account, Customer, Vendor, or Fixed Asset
  • Gen. Jnl Account No.: Main account value
  • Line Amount: Transaction amount
  • Transaction Date: Posting date

Journal Routing Fields

  • Journal Template: Optional transaction-level override
  • Journal Batch: Optional transaction-level override

If Journal Template/Batch are not provided on the transaction, the system uses Sales or Purchase defaults from Third Party Setup based on Transaction Type.

Balancing Account Fields

  • Bal. Account Type: Must be Bank Account or G/L Account
  • Bal. Account No.: Balancing account value

For Sales/Purchase journal processing, balancing account types other than Bank Account or G/L Account are rejected during validation.

Posting Setup Fields (Optional)

  • Gen. Posting Type
  • Gen. Bus. Posting Group
  • Gen. Prod. Posting Group
  • VAT Bus. Posting Group
  • VAT Prod. Posting Group
  • Bal. Gen. Posting Type
  • Bal. Gen. Bus. Posting Group
  • Bal. Gen. Prod. Posting Group
  • Bal. VAT Bus. Posting Group
  • Bal. VAT Prod. Posting Group

Currency and Document Fields (Optional)

  • Currency Code
  • Exch. Rate Factor
  • Journal Amount (LCY)
  • Document No.
  • Ext. Document No.
  • Gen. Jnl Doc Type
  • Description

Dimension Fields (Optional)

  • Shortcut Dimension 1-8 Code

Processing Workflow

Step 1: Import Transaction Data

Choose an import method:

Method A: File Import (XML/Excel)

  1. Open Third Party Transactions (Page 71112707)
  2. Filter to Application Area = Financial
  3. Run Import Transactions
  4. Select your configured Third Party Setup
  5. Select and import the file

Method B: API / Integration

  • Insert transaction records directly into ThirdPartyTransact_THI_LINC

Step 2: Validate Imported Data

  1. Select imported transactions
  2. Run Validate

Validation checks include:

  • Third Party Setup exists for Third Party Code
  • Transaction Type is Sales or Purchase
  • Main account resolved by mapping or direct mapping
  • Balancing account type is valid for this feature
  • Balancing account resolved (bank or G/L)
  • VAT posting groups resolved (when supplied)
  • Dimensions resolved (when imported and default dimensions are not forced)

Validation result:

  • Checked: Valid
  • Error: Validation failed (see Error Message)
  • Ignore: Excluded manually

Step 3: Create Sales / Purchase Journal Lines

  1. Filter to validated transactions (Val. Validation Status = Checked)
  2. Run one of the creation actions:
  • Create Sales Journal Lines
  • Create Purchase Journal Lines

Creation behavior:

  • Uses transaction Journal Template/Batch if provided
  • Otherwise uses Sales/Purchase defaults from Third Party Setup
  • Blocks creation if template/batch has open or pending approval entries
  • Applies line numbering in increments of 10000
  • Uses imported Document No., otherwise uses batch number series
  • Applies source code from journal template if not already assigned
  • Applies amount, currency, and exchange rate details
  • Applies imported posting setup based on setup flags
  • Applies imported dimensions when Use Default Dimensions is disabled
  • Archives processed Third Party transactions after successful creation

Step 4: Review and Post Journal Lines

  1. Open General Journals
  2. Select the relevant Sales or Purchase template/batch
  3. Review created lines (accounts, posting setup, amounts, dimensions)
  4. Post when ready

Validation Rules & Common Error Messages

Critical Errors

  • Third Party Setup for %1 was not found.
  • Journal Template and Batch must have a default value in Third Party Setup, if Journal Template and Journal Batch is empty.
  • Journal Template %1 and Batch %2 has open Approval Entries. Please complete the process before proceeding. Journal lines have not been created.
  • Balancing account type must be Bank Account or G/L Account for a Sales or Purchase journal.

Mapping Errors

  • No Mapped Gen. Jnl. Account Found.
  • No Mapped Bal. Account Found.

Troubleshooting Guide

1) Journal lines are not created

  • Verify transactions are in Checked status
  • Confirm Transaction Type is Sales or Purchase
  • Check that Journal Template and Journal Batch resolve correctly
  • Review approval workflow status on target batch

2) Account mapping failures

  • Add missing mapping records in Third Party Mappings
  • Enable Attempt Direct Mapping when external values match BC values
  • Confirm account exists and is not blocked

3) Balancing account errors

  • Use only Bank Account or G/L Account as balancing account type
  • Verify balancing account exists in BC
  • For bank balances, verify bank account code correctness

4) Posting setup validation errors

  • Verify posting groups exist and are valid combinations
  • Use Use Def. Post. setup Gen Jnl when account defaults should be used
  • Use Update Posting Setup Trans. Detail only when imported posting setup should override defaults

5) Dimension validation errors

  • Verify dimension values exist and are valid
  • Check mapping records for shortcut dimensions
  • Enable Use Default Dimensions if imported dimensions should be ignored

Best Practices

  1. Use separate Third Party Setup codes for Sales and Purchase sources when business rules differ.
  2. Keep dedicated journal batches for imports to avoid conflicts with manual entry users.
  3. Validate immediately after import and correct errors before creation.
  4. Start with small test imports before moving to production volumes.
  5. Use mapping for controlled value translation and auditability.
  6. Review journal lines before posting, even when automation is enabled.

Security & Permissions

Required permissions include:

  • Read/Write access to Third Party transaction and setup tables
  • Access to mapping and import mapping pages
  • Insert/Modify access to General Journal Line
  • Access to General Journal Templates and Batches
  • Posting permissions for General Journals (if auto-post is enabled)
  • Read access to account, bank, currency, VAT, and dimension master data