id |
integer |
Yes |
Yes |
nextval('sales_orders_id_seq'::regclass) |
Unique identifier |
order_no |
character varying(10) |
No |
No |
|
Sales Order number assigned from Company Settings, Sequence numbers or manually entered by the user |
cust_no |
character varying(20) |
No |
No |
|
Customer number - links to customers.cust_no |
cust_name |
character varying(60) |
No |
No |
|
Customer name |
status |
character varying(1) |
No |
No |
|
Sales Order status; C - Closed (used by Batch Invoicing) L - Deposit O - Open P - Processed S - Shipped |
order_date |
date |
No |
No |
|
Sales Order date |
division |
character varying(3) |
No |
No |
|
Division assigned to Sales Order |
location |
character varying(24) |
No |
No |
|
General Ledger Location segment for companies using Location accounting |
profit_center |
character varying(24) |
No |
No |
|
General Ledger Profit Center segment for companies using Profit Center accounting |
territory_code |
character varying(10) |
No |
No |
|
Territory code assigned to this Sales Order - links to territories.code |
salesperson_no |
character varying(10) |
No |
No |
|
Salesperson code assigned to this Sales Order - links to salespeople.salesperson_no |
cust_po_no |
character varying(20) |
No |
No |
|
Customer Purchase Order number |
ship_code |
character varying(10) |
No |
No |
|
Ship via code - links to shipping_methods.code |
required_date |
date |
No |
No |
|
Required date for Sales Order |
ship_carrier |
character varying(20) |
No |
No |
|
Ship carrier on the Sales Order |
ship_track_id |
character varying(50) |
No |
No |
|
Carrier tracking number from the Sales Order |
terms_code |
character varying(10) |
No |
No |
|
Payment terms code on the Sales Order - links to payment_terms.terms_code |
terms_description |
character varying(60) |
No |
No |
|
Payment terms description |
terms_days_before_due |
smallint |
No |
No |
|
Number of days from then Invoice date that the payment is due |
terms_days_allowed |
smallint |
No |
No |
|
Number of days from the Invoice date for which a discount is allowed |
terms_discount_rate |
numeric(5,2) |
Yes |
No |
|
Rate of the discount |
hold |
boolean |
No |
No |
|
Sales Order On Hold flag; FALSE - Not Held TRUE= Held |
fob |
character varying(20) |
No |
No |
|
Free on board location |
ref_no |
character varying(20) |
No |
No |
|
Reference number added by the user |
invoice_no |
character varying(10) |
No |
No |
|
The Invoice number to be assigned to this Sales Order |
invoice_date |
date |
No |
No |
|
Invoice date, also used for transaction date |
inv_date_rrule |
character varying(120) |
No |
No |
|
The recurring rules for this Standing Order |
batch_no |
bigint |
No |
No |
|
The batch number for this Sales Order, only used with Batch Invoicing |
was_quote_no |
character varying(10) |
No |
No |
|
Original Quote number before being converted to a Sales Order |
ship_id |
character varying(20) |
Yes |
No |
|
Customers Shipto ID selected for this Sales Order - links to addresses.ship_id |
currency |
character varying(3) |
No |
No |
|
Customer currency; blank = base currency - links to currencies.code |
currency_rate_method |
character varying(1) |
No |
No |
|
Currency rate conversion method used; / = direct * = indirect |
currency_rate |
numeric(13,7) |
Yes |
No |
|
Currency rate used |
discount |
numeric(5,2) |
Yes |
No |
|
Discount percentage on the entire Sales Order |
subtotal |
numeric(15,2) |
Yes |
No |
|
Subtotal before taxes, discount and freight |
total_discount |
numeric(15,2) |
Yes |
No |
|
Sales Order discount amount given on total, does not include line discounts |
freight |
numeric(15,2) |
Yes |
No |
|
Total freight on the Sales Order |
sales_tax |
numeric(15,2) |
Yes |
No |
|
Total Sales tax on this Sales Order |
gross_profit |
numeric(15,2) |
Yes |
No |
|
Gross profit for this Sales Order |
total_current_cost |
numeric(15,2) |
Yes |
No |
|
Total current cost of items on this Sales Order |
total_average_cost |
numeric(15,2) |
Yes |
No |
|
Total average cost of items on this Sales Order |
total |
numeric(15,2) |
Yes |
No |
|
Sales Order total |
total_payments |
numeric(15,2) |
Yes |
No |
|
Total payments made on this Sales Order including deposits |
backordered |
boolean |
No |
No |
|
Sales Order has back orders; False = no backorders True = has 1 or more backorders |
total_surcharge |
numeric(15,2) |
Yes |
No |
0 |
Total surcharges on Sales Order |
user_surcharge |
boolean |
No |
No |
|
Flag that indicates if the user edited the total surcharge amount; FALSE - Surcharge was not edited and will continue to be automatically calculated TRUE - Surcharge was edited and will no longer be automatically calculated. |
pack_date |
date |
No |
No |
|
Date Ship was last clicked on the Sales Order |
pack_init |
character varying(3) |
No |
No |
|
Users initials that last clicked Ship onthe Sales Order |
processed_user |
character varying(3) |
No |
No |
|
Initials of user that clicked Process on the Sales Order |
invoiced_user |
character varying(3) |
No |
No |
|
Initials of user that clicked Invoice on the Sales Order, used when set to batch invoicing |
subtotal_ordered |
numeric(15,2) |
Yes |
No |
|
Subtotal before taxes, discount and freight, based on order quantity |
total_discount_ordered |
numeric(15,2) |
Yes |
No |
|
Sales Order discount amount given on total, does not include line discounts, based on order quantity |
freight_ordered |
numeric(15,2) |
Yes |
No |
|
Total freight amount based on order quantity |
sales_tax_ordered |
numeric(15,2) |
Yes |
No |
|
Total sales taxes based on order quantity |
gross_profit_ordered |
numeric(15,2) |
Yes |
No |
|
Gross profit based on order quantity |
current_cost_ordered |
numeric(15,2) |
Yes |
No |
|
Total current cost based on order quantity |
average_cost_ordered |
numeric(15,2) |
Yes |
No |
|
Total average cost based on order quantity |
total_ordered |
numeric(15,2) |
Yes |
No |
|
Sales Order total based on order quantity |
backorder_created |
boolean |
No |
No |
|
A new Sales Order for the backorders has been created; FALSE - No TRUE - Yes |
cr_approve_amt |
numeric(15,2) |
No |
No |
|
Credit approved amount on this Sales Order |
cr_approve_date |
date |
No |
No |
|
The last date credit amount was approved |
cr_approve_user |
character varying(3) |
No |
No |
|
The initials of the user that approved the credit amount on this Sales Order |
job_no |
character varying(10) |
No |
No |
|
Job cost number - links to jobs.job_no |
job_acct_no |
character varying(10) |
No |
No |
|
Job cost account number - links to jobs.account |
phase_id |
character varying(20) |
No |
No |
|
The current Phase ID of this Sales Order - links to phases.phase_id |
contact_name |
character varying(60) |
No |
No |
|
Contact name on Sales Order |
contact_phone |
character varying(30) |
No |
No |
|
Contact phone number on Sales Order |
contact_fax |
character varying(30) |
No |
No |
|
Contact fax/cell number on Sales Order |
last_inv_no |
character varying(10) |
No |
No |
|
Not used |
last_inv_date |
date |
No |
No |
|
Not used |
contact_phone_type |
smallint |
No |
No |
|
Contact phone format type; 1 - Formatted number 2 - Unformatted number |
contact_fax_type |
smallint |
No |
No |
|
The type of fax number for this order; 1 - Formatted number 2 - Unformatted number 3 - Fax number 4 - Cell number |
contact_email |
character varying(254) |
No |
No |
|
Contact email address on Sales Order |
total_weight |
numeric(15,2) |
No |
No |
|
Total weight of the items on the Sales Order |
order_type |
character varying(1) |
No |
No |
|
The Sales Order type; B - Booking Order O - Sales Order Q - Quote R - RMA S - Standing Order W - Work Order |
ship_date |
date |
No |
No |
|
Date Ship was last clicked on the Sales Order |
standard_cost_ordered |
numeric(15,5) |
Yes |
No |
|
Total standard cost based on order quantity |
_dbversion |
integer |
No |
No |
|
Program version that last modified this record |
_created |
timestamp without time zone |
No |
No |
|
UTC Date and time record was created |
_created_by |
character varying(3) |
No |
No |
|
User initials that created this record |
_modified |
timestamp without time zone |
No |
No |
|
UTC Date and time this record was last modified |
_modified_by |
character varying(3) |
No |
No |
|
User initials that last modified this record |
sales_tax_rate |
numeric(7,4)[] |
Yes |
No |
'{0,0,0,0}'::numeric[] |
Tax 1 - 4 rates used on the Sales Order |
sales_tax_applicable |
numeric(15,2)[] |
Yes |
No |
'{0,0,0,0}'::numeric[] |
Tax 1 - 4 applicable amounts on the Sales Order |
sales_tax_total |
numeric(15,2)[] |
Yes |
No |
'{0,0,0,0}'::numeric[] |
Tax 1 - 4 totals for each tax on the Sales Order |
sales_tax_applicable_ordered |
numeric(15,2)[] |
Yes |
No |
'{0,0,0,0}'::numeric[] |
Tax 1 - 4 applicable amounts on the Sales Order, based on order quantity |
sales_tax_total_ordered |
numeric(15,2)[] |
Yes |
No |
'{0,0,0,0}'::numeric[] |
Tax 1 - 4 totals for each tax on the Sales Order, based on order quantity |
processed_date |
timestamp without time zone |
No |
No |
|
Date Process was last clicked on the Sales Order |
invoiced_date |
timestamp without time zone |
No |
No |
|
Date that Invoice was clicked on the Sales Order, used when set to batch invoicing |
user_freight |
boolean |
Yes |
No |
false |
Flag to indicate that the user did a freight override; FALSE = No TRUE = Yes |
udf_data |
hstore |
No |
No |
''::hstore |
User defined data for this record |
partial_tax_rate |
numeric(7,4) |
No |
No |
0 |
Partial tax rate used on the Sales Order |
partial_tax_total |
numeric(15,2) |
No |
No |
0 |
Partial tax total on the Sales Order |
_deleted |
timestamp without time zone |
No |
No |
|
UTC Date and time this record was deleted by user, blank if not deleted |
_deleted_by |
character varying(3) |
No |
No |
|
User initials that deleted this Sales Order, blank if not deleted |
total_standard_cost |
numeric(15,2) |
Yes |
No |
|
Total standard cost of items on this Sales Order |
total_surcharge_ordered |
numeric(15,2) |
Yes |
No |
0 |
Total surcharges on Sales Order based on order quantity |