View source | Discuss this page | Page history | Printable version   

ERP 2.50:Developers Guide/Database Model/org.openbravo.model.common.order/C OrderLine

ERP 2.50:Developers Guide/Database Model/org.openbravo.model.common.order

Index

Contents

C_OrderLine

The table defines the individual line items that comprise an Order

This table contains the following columns:

Name Nullable Data Type Description
C_OrderLine_ID NVARCHAR2(32)A unique and often automatically generated identifier for a sales order line.
AD_Client_ID NVARCHAR2(32)Client for this installation.
AD_Org_ID NVARCHAR2(32)Organizational entity within client
IsActive NCHAR(1)A flag indicating whether this record is available for use or de-activated.
Created NDATEThe date that this record is completed.
CreatedBy NVARCHAR2(32)User who created this records
Updated NDATEx not implemented
UpdatedBy NVARCHAR2(32)User who updated this records
C_Order_ID NVARCHAR2(32)A unique and often automatically generated identifier for a sales order.
Line NNUMBER(10, 0)A line stating the position of this request in the document.
C_BPartner_ID YVARCHAR2(32)Anyone who takes part in daily business operations by acting as a customer, employee, etc.
C_BPartner_Location_ID YVARCHAR2(32)The location of the selected business partner.
DateOrdered NDATEThe time listed on the order.
DatePromised YDATEThe date that a task, process, or action is to be completed or delivered by.
DateDelivered YDATEDate when the product was delivered
DateInvoiced YDATEThe time listed on the invoice.
Description YNVARCHAR2(2000)A space to write additional related information.
M_Product_ID YVARCHAR2(32)An item produced by a process.
M_Warehouse_ID NVARCHAR2(32)The location where products arrive to or are sent from.
DirectShip NCHAR(1)Ship direct from Vendor to Customer
C_UOM_ID NVARCHAR2(32)A non monetary unit of measure.
QtyOrdered NNUMBERThe number of an item involved in a transaction, given in standard units. It is used to determine price per unit.
QtyReserved NNUMBERReserved Quantity
QtyDelivered NNUMBERDelivered Quantity
QtyInvoiced NNUMBERThe total number of a product included in an invoice to a business partner.
M_Shipper_ID YVARCHAR2(32)The name of the company making the shipment.
C_Currency_ID NVARCHAR2(32)An accepted medium of monetary exchange that may vary across countries.
PriceList NNUMBERThe official price of a product in a specified currency.
PriceActual NNUMBERThe price that will be paid for a specified item.
PriceLimit NNUMBERThe lowest price a specified item may be sold for.
LineNetAmt NNUMBERThe final amount of a specified line, based only on quantities and prices.
Discount YNUMBERDiscount in percent
FreightAmt NNUMBERThe charge amount for a specified shipment.
C_Charge_ID YVARCHAR2(32)A cost or expense incurred during business activity.
ChargeAmt YNUMBERThe amount of a cost or expense incurred during business activity.
C_Tax_ID NVARCHAR2(32)The percentage of money requested by the government for this specified product or transaction.
S_ResourceAssignment_ID YVARCHAR2(32)x not implemented
Ref_OrderLine_ID YVARCHAR2(32)Reference to corresponding Sales/Purchase Order
M_AttributeSetInstance_ID YVARCHAR2(32)An attribute associated with a product as part of an attribute set.
IsDescription NCHAR(1)if true, the line is just description and no transaction
QuantityOrder YNUMBERThe number of a certain item involved in the transaction, shown in units which differ from the standard UOM.
M_Product_Uom_Id YVARCHAR2(32)The unit of measure being used for the request.
M_Offer_ID YVARCHAR2(32)The ability to raise or lower prices.
PriceStd NNUMBERThe regular or normal price of a product in the respective price list.
CANCELPRICEAD YCHAR(1)Used to activate or deactive the price adjustment for each line
C_Order_Discount_ID YVARCHAR2(32)null
Iseditlinenetamt YCHAR(1)A flag used to allow the end-user to edit Line Net Amount field.
Taxbaseamt YNUMBERThe total sum on which taxes are added.

Other Info

Check constraints

These are the check constraints for this table:

top

Indexes

These are the indexes for this table (for each index there is a list of all the columns included within it):

Non Unique

Unique

top

Columns

Sales Order Line

A unique identifier and a reference to a sales order line (product).

top

Client

Foreign key column to AD_Client table, (column: AD_Client_ID)

top

Organization

Foreign key column to AD_Org table, (column: AD_Org_ID)


Validation Rule AD_Org show child organizations: It only shows the child organizations of the organization's header. With the following code:

 
AD_ISORGINCLUDED(ad_org.ad_org_id, @AD_ORG_ID@, ad_org.ad_client_id)<>-1 AND IsReady='Y'

top

Active

There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reporting. There are two reasons for de-activating and not deleting records:
(1) The system requires the record for auditing purposes.
(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are existing invoices for it. By de-activating the Business Partner you prevent it from being used in future transactions.

top

Creation Date

The Created field indicates the date that this record was created.

top

Created By

Foreign key column to AD_User table, (column: AD_User_ID)

top

Updated

The Updated field indicates the date that this record was updated.

top

Updated By

Foreign key column to AD_User table, (column: AD_User_ID)

top

Sales Order

Foreign key column to C_Order table, (column: C_Order_ID)

top

Line No.

Indicates the unique line for a document. It will also control the display order of the lines within a document.

top

Business Partner

Foreign key column to C_BPartner table, (column: C_BPartner_ID)

top

Partner Address

Foreign key column to C_BPartner_Location table, (column: C_BPartner_Location_ID)


Validation Rule C_BPartner Location - Ship To: null. With the following code:

 
C_BPartner_Location.C_BPartner_ID=@C_BPartner_ID@ AND C_BPartner_Location.IsShipTo='Y' AND C_BPartner_Location.IsActive='Y'

Callout: SL_Order_Tax

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Tax Java class.

top

Order Date

Indicates the Date an item was ordered.

top

Scheduled Delivery Date

Scheduled Delivery Date indicates the date, if any, that an order was promised by.

top

Date Delivered

Date when the product was delivered

top

Invoice Date

The Date Invoice indicates the date printed on the invoice.

top

Description

A description is limited to 255 characters.

top

Product

Foreign key column to M_Product table, (column: M_Product_ID)

Callout: SL_Order_Product

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Product Java class.

top

Warehouse

Foreign key column to M_Warehouse table, (column: M_Warehouse_ID)


Reference Table M_Warehouse of Client With the following where clause:

 
M_Warehouse.AD_Client_ID=@#AD_Client_ID@ AND (select ad.isactive from ad_org ad where ad.ad_org_id = M_Warehouse.AD_Org_ID) = 'Y'


top

Direct shipment

Direct Shipment indicates if this line will ship directly from the vendor to the customer

top

UOM

Foreign key column to C_UOM table, (column: C_UOM_ID)

top

Ordered Quantity

The Ordered Quantity indicates the quantity of a product that was ordered.

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Reserved Quantity

The Reserved Quantity indicates the quantity of a product that is currently reserved for this order.

top

Delivered Quantity

The Delivered Quantity indicates the quantity of a product that has already been delivered.

top

Invoiced Quantity

The Invoiced Quantity indicates the quantity of a product that have been invoiced.

top

Shipping Company

Foreign key column to M_Shipper table, (column: M_Shipper_ID)

top

Currency

Foreign key column to C_Currency table, (column: C_Currency_ID)

top

List Price

The List Price is the official price stated by the selected pricelist and the currency of the document.

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Unit Price

The actual price indicates the price for a product in source currency.

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Price Limit

The Price Limit indicates the lowest price for a product stated in the Price List Currency.

top

Line Net Amount

Indicates the line net amount based on the quantity and the actual price. Any additional charges or freight are not included.

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Discount

The Discount indicates the discount applied as a percentage of the List Price.

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Freight Amount

The Freight Amount indicates the amount charged for Freight in the document currency.

top

Charge

Foreign key column to C_Charge table, (column: C_Charge_ID)

Callout: SL_Order_Charge_Tax

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Charge_Tax Java class.

top

Charge Amount

The Charge Amount indicates the amount for an additional charge.

top

Tax

Foreign key column to C_Tax table, (column: C_Tax_ID)


Reference Table C_Tax Parent is NULL With the following where clause:

 
C_Tax.Parent_Tax_ID IS NULL


Validation Rule C_Tax IsSOTrx: Validate tax depending on is Sales or Purchase transaction. With the following code:

 
(C_TAX.SOPOTYPE =(CASE WHEN @IsSOTrx@ = 'Y' THEN 'S' ELSE 'P' END) OR C_TAX.SOPOTYPE = 'B') AND C_TAX.AD_CLIENT_ID=@AD_CLIENT_ID@ AND C_TAX.C_TAX_ID=(CASE WHEN @IsSOTrx@ = 'Y' AND EXISTS(SELECT 1 FROM AD_ORGINFO WHERE ISTAXUNDEDUCTABLE='Y' AND AD_ORG_ID=@AD_ORG_ID@) THEN (SELECT C_TAX_ID FROM AD_ORGINFO WHERE ISTAXUNDEDUCTABLE='Y' AND AD_ORG_ID=@AD_ORG_ID@) ELSE C_TAX.C_TAX_ID END)

top

Resource Assignment

The ID identifies a unique record

top

SO/PO Reference

Foreign key column to Ref_OrderLine table, (column: null)

top

Attribute Set Value

Foreign key column to M_AttributeSetInstance table, (column: M_AttributeSetInstance_ID)

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

Description Only

If a line is Description Only, e.g. Product Inventory is not corrected. No accounting transactions are created and the amount or totals are not included in the document. This for including descriptional detail lines, e.g. for an Work Order.

top

Order Quantity


Product quantity in the order uom.

Callout: SL_Order_Conversion

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Conversion Java class.

top

Order UOM

Foreign key column to M_Product_UOM table, (column: M_Product_Uom_Id)


Reference Table M_Product_UOM With the following where clause:

 
M_Product_UOM.M_Product_ID = @M_Product_ID@


Callout: SL_Order_Conversion

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Conversion Java class.

top

Price Adjustment

Foreign key column to M_Offer table, (column: M_Offer_ID)

top

Standard Price

The Standard Price indicates the standard or normal price for a product on this price list

top

Cancel Price Adjustment

If the user wants not to apply price adjustment to a specific line should use this check to achieve it

Callout: SL_Order_Amt

This element is linked to a callout.

It is implemented by org.openbravo.erpCommon.ad_callouts.SL_Order_Amt Java class.

top

C_Order_Discount_ID

Foreign key column to C_Order_Discount table, (column: C_Order_Discount_ID)

top

Edit Line Amount

A flag used to allow the end-user to edit Line Net Amount field.

top

Alternate Taxable Amount

top

Related tables

Tables that link this table:

top

Retrieved from "http://wiki.openbravo.com/wiki/ERP_2.50:Developers_Guide/Database_Model/org.openbravo.model.common.order/C_OrderLine"

This page has been accessed 5,167 times. This page was last modified on 14 June 2011, at 11:04. Content is available under Creative Commons Attribution-ShareAlike 2.5 Spain License.