Minimum Version Required: 22.01
Pre-Conditions
Accounts Payable module must be enabled in your system
Vendors should exist in your system, though the routine can create missing vendors
User must have the GeneralAccountingEdit permission
If using currency features, the Currency module must be enabled and currencies must exist
Steps
The AccountsPayable EDBL routine imports accounts payable transactions (bills) that your company owes to vendors. It handles:
Creating or updating purchase records and their associated shipments
Setting payment information, including open balances
Creating vendor records if they don't exist
Handling payment applications
Managing multi-currency transactions (if enabled)
The routine matches to existing purchases using:
Transaction ID (TxnID) and Vendor ID (with matching date)
Invoice number and Vendor ID (with matching date)
Shipment ID and Vendor ID
When creating new purchases, the routine:
Creates shipment records with Shipment Type = "Imported Inventory"
Creates purchase records with appropriate vendor and invoice information
Sets AP terms and due dates
Updates open balances
The "ZeroImportedAccountsPayable" option, when set to "1", will zero out previously imported AP records from the same import group. This is useful when completely replacing AP data rather than adding to it.
Fields And Definitions
Required Fields:
VendorID/VendorID_Translation - The vendor who issued the bill
InvoiceNum - The invoice number (will default to PONum if missing)
OpenBalance - The amount still owed on this invoice
Key Optional Fields:
ImportGroupID - Groups imports together (defaults to "1")
CompanyID/CompanyID_Translation - Company identifier (defaults to user's company)
Date/InvoiceDate - Date of purchase/invoice (they default to each other if one is missing)
DateMMDDYY/DateYYYYMMDD - Alternative date formats that will be converted
PONum - Purchase order number
Memo - Notes about the transaction
APAccountID - Accounts payable account
CheckNum - Check number for payments
APTerm - Payment terms
DaysOfCredit - Credit terms days
ZeroImportedAccountsPayable - Set to "1" to zero out prior imported AP
LocationID/LocationID_Translation - Location identifier
Vendor Creation Fields:
Address, Address2, City, State, PostalCode - Vendor address details
ListID, LicenseNum - External identifiers for the vendor
Multi-Currency Fields:
CurrencyID/CurrencyID_Translation - Currency identifier (if multi-currency enabled)
ExchangeRate - Exchange rate for currency conversion (defaults to "1")
Best Practices
Always include date fields - While the system provides defaults, explicit dates ensure accuracy
Provide vendor information - If vendor IDs don't match, include VendorID_Translation to link to existing vendors
Group related imports - Use consistent ImportGroupID values to keep related imports together
Check ZeroImportedAccountsPayable setting - Only set to "1" when you want to clear previous imports
Verify vendors first - Import vendors before accounts payable to ensure proper linking
Include invoice numbers - Without InvoiceNum, matching to existing purchases becomes difficult
Set company information - If you have multiple companies, explicitly set CompanyID to ensure correct company assignment
Import in batches - For large datasets, consider breaking imports into manageable chunks by date range
Review translations - If imports fail to match existing records, check TableTranslations for proper mapping