How to Write a Plug-In Interface

Similar documents
Distribution Training Guide. D110 Sales Order Management: Basic

Comparison of Alteris BMS and SBE

Sage 300 ERP What's New

Sage Accpac ERP Order Entry 5.3A Service Pack 5 (070309)

for Sage 100 ERP Sales Order Overview Document

6A. RMA Processing. How does an RMA work?

for Sage 100 ERP Purchase Order Overview Document

CHAPTER 1: SALES ORDER MANAGEMENT

Sage Cloud Connector Getting Started Guide. January 2014

BackOffice 7.3 Bet a Release Notes BackOffice 7.3 Release Notes Accounts Receivable New Features Open Issues

MODULE 4: PURCHASE ORDER MANAGEMENT

Accounts Payable and Inventory Management

ACCEPTING CREDIT CARDS AS PAYMENT

This paper describes many of the rules we have encountered computing commissions and rebates for the food industry.

SAP BusinessObjects Accounts Receivable Rapid Mart XI 3.2, version for SAP solutions - User Guide

Recurring Contract Billing Importer 2013

Accounts Receivable User Manual

Keep your search simple. Only the last name is required. First name and Phone are optional.

Microsoft Dynamics CRM Adapter for Microsoft Dynamics GP

Sage 300 ERP Sage CRM 7.2 Integration Upgrade Guide

AR Part 1: An Introduction to Accounts Receivable

Database Normalization. Mohua Sarkar, Ph.D Software Engineer California Pacific Medical Center

TheFinancialEdge. Concepts Guide for Accounts Receivable

3.GETTING STARTED WITH ORACLE8i

The POS system can track sales by various payment methods like cash, checks, credit cards, coupons, and gift certificates.

2. A typical business process

Microsoft Dynamics SL (Solomon)

Klarna Magento module

How To Post A Cash Receipt On A Bank Account On A Credit Card On A Microsoft Nokia (Aero) (Ahem) (For A Creditcard) (Or A Bank Card) ( For A Credit

Company Data Archive Version 9.0

The 3 Normal Forms: Copyright Fred Coulson 2007 (last revised February 1, 2009)

CHAPTER 4: PURCHASE ORDER MANAGEMENT

Accounts Receivable. Chapter

Accounts Payable Expense Distribution Tables

Retail POS User s Guide. Microsoft Dynamics AX for Retail

A Short Tutorial on Using Visio 2010 for Entity-Relationship Diagrams

4. Do not make changes to the Master record. To create a custom form, click Copy.

Version 7.40 Customer Upgrade Guide. Sage ERP MAS 500

TheFinancialEdge. Records Guide for Accounts Payable

AP and AR Corrections Handout

Integrating Microsoft Dynamics GP and Microsoft Dynamics CRM. Discussion Paper and FAQ s

Jet Data Manager 2012 User Guide

Recurring Contract Billing 10.0 SP6

Technology Foundations. Conan C. Albrecht, Ph.D.

Distribution Training Guide. D100 Inventory Management: Basic

for Sage 100 ERP Accounts Receivable Overview Document

Crystal Reporting. Accounting and Management Products 9.6 CD

ACCTivate! Release Notes (QuickBooks Edition)

Accounts Receivable Reference Guide

Sales Analysis Reports by Salesperson AR-1021

Oracle Sales Compensation

Creating and Using Databases with Microsoft Access

Adagio Invoices. Version 9.1A First Edition. All product names mentioned are trademarks or service marks of their respective owners.

Sage 300 ERP Payment Processing User's Guide

Microsoft Dynamics GP. Working with Crystal Reports

for Sage 100 ERP General Ledger Overview Document

Accounts Receivable Processing

Introduction This document s purpose is to define Microsoft SQL server database design standards.

Klarna Online User Manual

AP INTEGRATION Serengeti Managed Web Service Overview

Sage 300 ERP General Ledger User's Guide

Time Matters and Billing Matters 12 SP2. Release Notes. What's new in this release. Obtaining the software. Before you install. Time Matters 12 SP2

Sage 300 ERP Tax Services User's Guide

Sales Person Commission

How to handle Factoring in your Sage BusinessWorks

Technical Specifications

for Sage 100 ERP Accounts Payable Overview Document

USERV Auto Insurance Rule Model in Corticon

INVENTORY MANAGEMENT

Directions for the AP Invoice Upload Spreadsheet

InventoryControl for use with QuoteWerks Quick Start Guide

D a n s k e B a n k M e s s a g e I m p l e m e n t a t i o n G u i d e. M a s t e r C a r d C o r p o r a t e C a r d T r a n s a c t i o n s

AR Collections Manager for Microsoft Dynamics SL

Trouble Shooting Guide for Reconciling AR Account

Table of Contents INDEX...47

Fundamentals of Database System

Livestock Office Payments: Creditor Cashbook Transactions

Welcome to the handling payments topic. 2-1

CHAPTER 1: JOBS OVERVIEW AND SETUP

New Features in Sage BusinessVision 2013 (version 7.6)

CPM release notes

Microsoft Access 2007 Module 1

How To Improve Your Business Software

Accounts Payable. MaddenCo Inc. Revised October, Copyright 2015 by MaddenCo, Inc All rights reserved.

Inventory Management Overview Document. for Sage 100 ERP

Solar Eclipse Accounts Receivable. Release 8.7.2

DIRECT PAYMENTS (ACH TRANSFER MODULE)

KMx Enterprise: Integration Overview for Member Account Synchronization and Single Signon

Accounts Receivable: Importing Remittance Data

Epicor ERP Epicor ERP Accounts Receivable Transaction Hierarchy

AVATAX 15 USER GUIDE

Creating Database Tables in Microsoft SQL Server

Accounts Receivable / Credit Management

Invoice, Statement, and Deposit Slip Layout Variables

User Guide View Invoices and Payments

Access Queries

Access Queries (Office 2003)

Transcription:

How to Write a Plug-In Interface Overview CommissionCalc is a software application which computes sales-based incentive from data in an ERP database. It is described at www.commissioncalc.com. This spec defines a standard set of tables, the CC Input Tables, from which CommissionCalc can read data. The CC Input Tables are stored in a Microsoft SQL database. Database Schema The columns listed for each table below are required. In addition, you can add whatever other columns are used to compute your commission. I. Accounts Receivable tables with transactional data. These 2 tables contain financial transactions. They do not contain product data. A. CC_ArTransactions. This required table contains one row for each invoice, payment, credit memo, or debit memo. (See section V.D for a definition of payment.) a) ArDocType. (See section V.B for a listing of document types.) b) ArDocId. Ordinarily, the ERP system assigns a unique ID to each CC_ArTransactions row. Use that number. For example, if the row represents an invoice, ArDocId is the invoice number. Rarely, the ERP system does not assign a unique ID to each CC_ArTransactions row. In this case, create an ID by concatenating columns or by using an ERP2CC identity column. c) CustomerId d) DocDate e) DueDate. If the row is not an invoice, Null. f) ArCreditType. (See section V.C for a listing of credit types. If your commission plan does not require this information, you may leave this column blank.) g) Amount. The net amount of the transaction in the home currency, after all discounts and other adjustments which are included in the row. If ArDocType is R, C. or P, the sign will always be negative. If ArDocType is I, the sign will ordinarily be positive; however, if the ERP system permits invoices for negative quantities and amounts, the sign may occasionally be negative. If ArDocType is D, the sign will always be positive. 2. Indexes 2007-2010 Flaum Technologies Inc. p. 1 of 7 revised Sept. 5, 2010

a) Primary: ArDocType + ArDocId b) Secondary: CustomerId + DocDate B. CC_ArApplications. This required table contains one row for each application of a payment, credit memo, or debit memo to an invoice. If a payment represents a single application of a check to an invoice, there is one row in CC_ArApplications for each payment row in CC_ArTransactions. If a payment represents a check which might be applied to several invoices, there may be multiple rows in CC_ArApplications for each payment; see Appendix A for an illustration of this multiple-row design. a) DateApplied b) CustomerId c) ApplyFromArDocType d) ApplyFromArDocId e) ApplyToArDocType. This must always be I. f) ApplyToArDocId g) Amount. This is the net amount of the application, in the home currency, after all discounts and other adjustments included in the row. The sign should be negative if the application reduces the amount due and positive otherwise. 2. Indexes a) Primary: ApplyFromArDocType + ApplyFromArDocId. ApplyToArDocType and ApplyToArDocId may be appended if it is desired to make this index unique, and therefore useable as a clustered index. b) Secondary: (1) ApplyToArDocType + ApplyToArDocId. (2) CustomerId. II. Sales History Tables. These 2 tables normally contain data about product which has been invoiced or returned, including item numbers, quantities invoiced, prices, and the like. Exception: if commission is paid when orders are booked, sales orders can be copied to these tables before they are invoiced. Such orders should be coded as preliminary invoices; please discuss this with FTI. A. CC_InvoicedOrderHeader. This required table normally contains one row for each invoice or return. It has a one-to-many relationship with CC_InvoicedOrderLines. Because a single sales order can be shipped in multiple parts, with each part having a separate invoice, it has a many-toone relationship with sales orders. 1. Required Columns a) Link to AR invoice or return (i.e. credit memo). (1) ArDocType. (See section V.B for a listing of document types.) (2) ArDocId b) CustomerId 2007-2010 Flaum Technologies Inc. p. 2 of 7 revised Sept. 5, 2010

c) Addresses. These columns are used for ERP systems which store addresses in a separate table and reference them by an address code. If the addresses are stored in columns which will be part of CC_InvoicedOrderHeader, they can be {blank} or Null. (1) BillToAddressId (2) ShipToAddressId 2. Indexes a) Primary: ArDocType + ArDocId. b) Secondary: CustomerId. B. CC_InvoicedOrderLines. This required table contains one row for each item on the invoice, return, or sales order. a) Link to AR invoice or return (i.e. credit memo). (1) ArDocType. (See section V.B for a listing of document types.) (2) ArDocId b) Line identification (1) OrderLineSeq. (2) OrderLineKitSeq. Usually zero. OrderLineKitSeq is a second segment for OrderLineSeq which is intended to support kitting, a feature of some ERP systems which allows invoice lines to contain subordinate lines representing kit components. c) Line data: ItemId 2. Primary key: ArDocType + ArDocId + OrderLineSeq + OrderLineKitSeq. III. Master Data A. CC_ItemMaster. Optional table. 1. Required column: ItemId 2. Primary key: ItemId B. CC_CustomerMaster. Required table. a) CustomerId b) CustomerName 2. Primary key: CustomerId C. CC_SalespersonMaster. Required table. a) SalespersonId b) Name 2. Primary key: SalespersonId D. CC_Addresses. Optional table. 2007-2010 Flaum Technologies Inc. p. 3 of 7 revised Sept. 5, 2010

a) CustomerId b) AddressId. This code must be unique for any given customer. It may also be globally unique, but that is not required. 2. Primary key: CustomerId + AddressId. IV. ERP Commission Data. These tables are optional and are usually not used; the data is often stored in the sales history tables instead. Typically they are used if (a) you want the ERP system to identify an unlimited number of salespeople for each order or order line or (b) the ERP system has similar tables so using these simplifies programming ERP2CC. You may use either one or both of these tables. A. CC_CommissionSplits 1. Data columns a) ArDocType b) ArDocId c) CustomerId d) SplitsSeq, where SplitsSeq is 1 for the first salesperson associated with an ERP order header, 2 for the second, etc. 2. Primary key: ArDocType + ArDocId + SplitsSeq B. CC_CommissionLineSplits. 1. Data columns a) ArDocType b) ArDocId c) OrderLineSeq d) CustomerId e) SplitsSeq, where SplitsSeq is 1 for the first salesperson associated with an ERP order line, 2 for the second, etc. 2. Primary key: ArDocType + ArDocId + OrderLineSeq + SplitsSeq 2007-2010 Flaum Technologies Inc. p. 4 of 7 revised Sept. 5, 2010

V. Miscellaneous Information A. Table Name Suffixes. CommissionCalc might be executed by multiple users simultaneously, all using the same SQL database. Therefore, two or more copies of each of the above tables, and any ERP2CC work tables, might exist simultaneously. To make this possible, the actual database name for each table will have a suffix consisting of an underscore and the computer name of the workstation on which CommissionCalc is executing. For example, if CommissionCalc is executed on computer ABC, the first table above will actually be named CC_InvoicedOrderHeader_ABC. (Implementation note: Do not use the Windows API function GetComputerName or the VB.Net property My.Computer.Name to read the computer name because they convert lower case letters to capitals; Microsoft acknowledges that this (or, anyway, part of it) is a defect which they will change in a future release. ERP2CC can use the VB.Net property Dns.GetHostName() because this returns a properly capitalized name regardless of the version of Windows being used.) B. ArDocType. CHAR(1). The following values can be used. A plug-in interface need not use all of these values. Types A and S can be used only if CC_CommissionSplits and CC_CommissionLineSplits are not used. 1. I = Invoice 2. P = Payment 3. R = Return (i.e. credit with item data) 4. C = Credit Memo (i.e. credit without item data) 5. D = Debit Memo (i.e. no item data) 6. A = Adjustment. CommissionCalc treats these exactly the same as type C. It is provided because some accounting systems have separate adjustment transactions and it might be desirable to maintain the distinction between A & C for user convenience. Note: With some accounting systems, adjustments can change values which credit memos cannot change, such as due date. CommissionCalc does not support changing these values. 7. S = Discount for prompt payment. C. ArCreditType. CHAR(1). Many ERP systems have columns in AR transaction tables which are dedicated to specific, common types of credits. ERP2CC will create separate CC_ArApplications rows for these credits and use ArCreditType indicate the source of the credit as follows. If a specific ERP system requires more than the following codes, please discuss the requirements of that system with FTI. 1. W = write off 2. P = discount for prompt payment 3. M = miscellaneous credit (i.e. any credit other than the above) 4. {blank} = ArDocType <> C D. Two alternative definitions of payment are used by different ERP systems. A payment can represent a single check, wire transfer, or other transfer 2007-2010 Flaum Technologies Inc. p. 5 of 7 revised Sept. 5, 2010

of funds; thus, one payment could be applied to several invoices. Alternatively, a payment can be the portion of a check, etc. which is applied to a single invoice. It will probably simplify development of ERP2CC if you use the same definition as your ERP software uses. 2007-2010 Flaum Technologies Inc. p. 6 of 7 revised Sept. 5, 2010

Appendix A Payment Application The following diagram shows how a $500 check would be applied to 2 invoices when the first definition of payment in section V.D is used. The first invoice is paid in full. The second invoice still has an open balance of $150. CC_ArTransactions CC_ArApplications ArDocType = P (Payment) ArDocId = 100 Total Payment Amount = $500. ArDocType = I (Invoice) ArDocId = 3985 Total Payment Amount = $300. ArDocType = I (Invoice) ArDocId = 3986 Total Payment Amount = $350. ApplyFromArDocType = P ApplyFromArDocId = 100 ApplyToArDocType = I ApplyToArDocId = 3985 Amount = $300. ApplyFromArDocType = P ApplyFromArDocId = 100 ApplyToArDocType = I ApplyToArDocId = 3986 Amount = $200. NB: Each invoice, payment, or other A/R document is represented by exactly one row in CC_ArTransactions, regardless of how many other A/R documents it is associated with. Instead of splitting payments into multiple rows to represent multiple applications or splitting invoices to reflect the amount paid by each check, transactions are distributed via the CC_ArApplications table. 2007-2010 Flaum Technologies Inc. p. 7 of 7 revised Sept. 5, 2010