-- ABS-90563 / ABS-90631
--- ARTRANSACTION ---
ALTER TABLE ARTRANSACTION DROP CONSTRAINT CHK_ARTRANSACTION_ORIGIN;

COMMENT ON COLUMN ARTRANSACTION.ORIGIN IS 'This field is only used internally for trouble shooting. It identifies where the ARTransaction is created.
0 = Undefined
1 = Finalize invoices
2 = Consolidated invoices
3 = Settlement
4 = Generate statement
5 = Cash application – Manual added
6 = Cash application – Generated (apply)
7 = DB Procedure ProcessPaymentTransaction
8 = DB Procedure ProcessUnappliedCredit
9 = Credit card transactions – cancel / refund
10 = Process credit card transactions
11 = Credit Card Portal
12 = Customer Financials – Credit card on demand
13 = Web Portal Credit Card payment
14 = Scheduled Credit Card Payment
15 = Card Test transaction
16 = Scheduled ACH Payment
17 = Route Assistant from Mark other invoices';

ALTER TABLE ARTRANSACTION ADD CONSTRAINT CHK_ARTRANSACTION_ORIGIN CHECK (ORIGIN BETWEEN 0 AND 17);

