Anda di halaman 1dari 12

T a b le -

R A_C USTO M ERS


C o lu m n

Oracle Applications Data Structure C U S T O M E R _ ID C U S T O M E R _ N A M E


1 0 0 0 B u s in e s s W o r ld
C U S T O M ER _ N U M BER C U S T O M ER _C L A S S _C O D E S A L ES _C H A N N EL _C O D E

1 0 0 1 A m e r ic a n T e le p h o n e a n d T e le g r a p h
1 0 0 3 U n it e d P a r c e l S e r v ic e
1 0 0 0 H ig h T e c h n o lo g y
1 0 0 1 T e le c o m
1 0 0 3 O th e r
C o m m e r c ia l
C o m m e r c ia l

1 0 0 5 A T & T U n iv e r s a l C a r d 1 0 0 5 T e le c o m C o m m e r c ia l R e c o rd

by Jenny Chan, Red Rock Consulting


1 0 0 6 C o m p u t e r S e r v ic e a n d R e n t a ls 1 0 0 6 O th e r C o m m e r c ia l
1 0 0 7 G e n e r a l T e c h n o lo g ie s 1 0 0 7 H ig h T e c h n o lo g y C o m m e r c ia l
1 0 2 1 V is io n 1021 In t e r n a l
1 0 0 2 Im a g in g In n o v a t io n s , In c . 1 0 0 2 H ig h T e c h n o lo g y C o m m e r c ia l
1 0 0 8 T o t a l In t e r n e t 1 0 0 8 H ig h T e c h n o lo g y C o m m e r c ia l
1 1 4 6 D e p a rtm e n t o f D e f e n s e 1 0 8 6 O th e r
1 1 4 8 F e d e r a l P a r ts 1087
1 1 5 0 M o d e rn T ru c k 1 0 8 8 O th e r
1 0 0 4 H ilm a n a n d A s s o c ia t e s 1 0 0 4 H ig h T e c h n o lo g y C o m m e r c ia l

Introduction
1 2 5 6 R e d R o c k C o n s u lt in g 1109
1 2 5 7 S h e ll R o c k C o n s u lt in g 1110

V ie w -
C A R_C O M M _C USTO M ER_V

Oracle Applications has a very flexible architecture C U S T O M E R _ ID C U S T O M E R _ N A M E CU S TO M ER _N U M B ER CU S TO M ER _C LA S S _C O DE

containing valuable information but with flexibility comes 1 0 0 0 B u s in e s s W o r l d


1 0 0 1 A m e r i c a n T e le p h o n e a n d T e le g r a p h
1 0 0 5 A T & T U n iv e r s a l C a r d
1 0 0 0 H i g h T e c h n o lo g y
1 0 0 1 T e le c o m
1 0 0 5 T e le c o m

complexity in the underlying data structure. 1 0 0 6 C o m p u t e r S e r v i c e a n d R e n t a ls


1 0 0 7 G e n e r a l T e c h n o l o g ie s
1 0 0 6 O th e r
1 0 0 7 H i g h T e c h n o lo g y

Understanding the basic Oracle Applications structure is


1 0 0 2 Im a g i n g In n o v a t io n s , In c . 1 0 0 2 H i g h T e c h n o lo g y
1 0 0 8 T o t a l In t e r n e t 1 0 0 8 H i g h T e c h n o lo g y
1 0 0 4 H il m a n a n d A s s o c ia t e s 1 0 0 4 H i g h T e c h n o lo g y

critical in retrieving important and relevant content. This


information is an asset and when used appropriately can
be used as a competitive advantage.
Synonym
This article provides a high level overview of the Oracle Another name assigned to a table for easy identification
Applications data structure and some business examples. and used for data classification between Oracle
However, before we get understand the data structure Application modules.
there is some technical terminology that needs
explanation.
Primary Key
The business examples will be illustrated in Oracle
SQL*Plus but you can use the same table joins in your The column or columns that uniquely identify each row of
preferred reporting writing tool such as Oracle a table.
Querybuilder and Oracle Discoverer.
Foreign Key
Please refer to the Oracle Technical Reference manuals for
more detail on the entity data models, table descriptions One of more columns in one table whose values refer to
and functional decomposition. the primary key values in another table.

Also note that the following information is based on Query


Oracle Applications Release 11.03 data structures.
Series of command to instruct the database to retrieve the
Definitions data you have specified.

Table Relationship

The basic entity of storage in a relational database A connection between two or more tables.
management system.
Entity Relationship Diagram (ERD)
Consist of one or more units of information (records) each
of which contains a number of data elements or fields (or Diagram that display the relationships between tables.
columns).

E
R D RA_CUST
O MERS(R
C)
CU
STOME
R_ID N
UM

Record/Row C
U
C
U
S
S
T
T
O
M
O
M
E
E
R
R
_
N
_
N
A
U
M
M
E
BER
V
V
C
2
C
2
P
rim
aryK
ey

S
TATU
S VC
2
CU
STOME
R_ T
YPE VC
2

One set of related information contained in a table. C


U
C
S
U
S
T
T
O
M
O
E
M
R
E
R
_
P
_
RO
CL
A
S
S
P
E
S
C
_
T
C
_
O
G
D
R
O
E
U
P V
V
C
2
C
2
CU
STOME
R_ CATEGORY_
C ODE VC
2

Column/Field R
elatio
nsh
ip

R A
_AD
DRE
SSE
S_AL
L(R
A)

A subdivision of a table, with a column name and a


AD
DRESS_ID N
U M
CU
STOMER _ID N
U M
S
TATUS VC2

specific datatype. C
O
A
U
D
D
N
R
T
E
R
S
Y
S1
V
V
C
C
2
2
F
ore
ignKe
y

AD
DRESS2 VC2
AD
DRESS3 VC2
AD
DRESS4 VC2
C
IT
Y VC2

View P
O
S
T
S
A
T
T
A
E
L_
CO DE V
V
C
C
2
2
ORG_
ID N
U M

A datasource made up of columns from one or more


database tables combined into one logical table or object.
Tips

 There is a screen in Oracle Applications where you


would like to report the information.

Click on Help > About This Record from the Menu.

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
APPS

AR GL AP

FND FA CM
 There is a table name (e.g. ITEM) you would like to
use but unsure of the exact name. OE INV PO
Login to SQL*Plus and type
SELECT table_name Oracle Applications Data Structure
FROM all_tables
WHERE table_name LIKE ‘%ITEM%’
Oracle General Ledger
 There is a column (e.g. CUSTOMER_NAME) that you
would like to use but unsure which table the column Gl_code_combinations
belongs to.
 Setup > Accounts > Combinations
Login to SQL*Plus and type
This table stores the valid account combinations.
SELECT table_name, column_name
FROM all_tab_columns The value in your chart of account segments are stored in
WHERE column_name = ‘CUSTOMER_NAME’ the columns segment1 to segment30 depending on your
 The columns org_id and organization_id are different. application configuration.
Organisation_id refers to the inventory organisations
in Oracle Inventory and org_id refers to the operating For example, say your chart of accounts is
unit. Company – Cost Centre – Account
then segment1 = company, segment 2 = cost centre and
segment3 = account.
 Table names that ends with _all has the column
However, this sequencing of segments is not guaranteed
org_id included. The org_id signifies the operating
therefore, its best to check your configuration.
unit. Therefore, if you have multi-organisation
functionality, you will need to use the _all tables.
Note that not all tables will have _all suffix. Another important column is the account_type which
signifies your account is an Asset, Liability, Revenue,
Expense or Owners Equity account.
 The majority of the entities describes in the following
are tables but you may find that there is a view that
Gl_je_batches
combines all your requirements. These views will be
based on non _all tables. You need to type the
following in SQL*Plus to see the data in these views.
 Journals > Enter

exec dbms_application_info.set_client_info(org_id) This table stores the journal entry batches. Journal entries
are batched in General Ledger.
Org_id is the operating unit in hr_organization_units.
Some columns of interest includes :
 The following illustrates a simplified view of the
 Name
Oracle Applications data schema. Each data schema
is mapped to an application module. The apps  Set_of_books_id (when you have more than one set of
schema has a number of synonyms and views of all book, you’ll also need to link to gl_sets_of_books)
the Oracle Application modules. The fnd has all the
 Status
schema all the Oracle Application foundation
information such as user profiles, responsibility and  Default_period_name
value sets.  Posted_date
You need to login to the appropriate schema when
using query tools on a table. Therefore, consult your  Posting_run_id
Database Administrator regarding security to the
Gl_je_headers
schema/schemas you need access.
 Journals > Enter

This table stores the journal entry headers. There is always


two journal lines for each journal header.

Some columns of interest includes :

 Je_category

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
 Period_name disribution, that is this table corresponds to the
Distributions window.
 Set_of_books_id (when you have more than one set of
book, you’ll also need to link to gl_sets_of_books)
Some columns of interest includes :
 Posted_flag
 Line_type_lookup_code
 Je_source
 Dist_code_combination_id (credit entry)
 Name
 Accts_pay_code_combination_id (debit_entry)
 Status
 Base_amount (in functional currency)
Gl_je_lines
Ap_checks_all
 Journals > Enter
 Payments > Entry > Payments
This table stores the journal entry lines.
This table stores payments to suppliers.
The entered_dr and entered_cr stores the amount in the
entered currency whereas the accounted_dr and Some columns of interest includes :
accounted_cr stores the amount in the functional currency.
 Amount (in functional currency)
Other columns of interest includes :  Check_date

 Set_of_books_id (when you have more than one set of  Bank_account_name


book, you’ll also need to link to gl_sets_of_books)  Check_number
 Period_name  Payment_method_lookup_code
 Status  Payment_type_flag
 Description
Ap_invoice_payments_all
 Reference_1..reference10 (these columns links back to
your Subledgers)  Payments > Entry > Payments

For example, for Purchasing transactions This table stores invoice payments to suppliers. This table
is updated when you confirm an automatic payment
Reference_1 = ‘PO’ batch, enter a manual payment or process a Quick
Reference_2 = po_headers_all.po_header_id Payment. Void payments are represented as a negative of
Reference_3 = po_distributions_all.po_distribution_id the original payment line.
Reference_4 = po_headers_all.segment? (this is the
purchase order number Some columns of interest includes :

 Accounting_date
Oracle Payables
 Period_name
Ap_invoices_all
 Amount
 Invoices > Entry > Invoices  Payment_num

This table stores all the invoices you enter. For an invoice Ap_payment_distributions_all
to be approved, the total invoice amount must be stored in
ap_invoice_distributions_all and  Payments > Entry > Payments
ap_payment_schedules_all.
This table stores accounting information for payments.
Some columns of interest includes : There is at least one CASH payment distribution for each
invoice payment. Additional rows may include
 Invoice_num DISCOUNT, GAIN and LOSS distributions where
appropriate.
 Invoice_date
 Amount_paid Some columns of interest includes :
 Invoice_currency_code
 Line_type_lookup_code
 Invoice_type_lookup_code (CASH/DISCOUNT/GAIN/LOSS)
 Payment_status_flag  Base_amount

Ap_invoice_distributions_all
Oracle Purchasing
 Invoices > Entry > Invoices Po_vendors

This table stores the accounting information for the invoice  Supply Base > Suppliers
you have entered. There is one row for each invoice
This table stores supplier information.

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
Some columns of interest includes : This table stores purchase order shipment schedules and
blanket agreement price breaks. A purchase order is
 Segment1 (supplier number) closed when QUANTITY is equal to
 Vendor_name QUANTITY_RECEIVED.

 Terms_id
Some columns of interest includes :
 Vendor_type
 Quantity
 Ship_to_location (link to hr_locations for location
information)  Quantity_accepted
 Bill_to_location (link to hr_locations for location  Quantity_received
information)  Quantity_cancelled
Po_vendor_sites_all  Need_by_date
 Ship_to_organization_id (link to
 Supply Base > Suppliers
org_organization_definitions for the organization
code)
This table stores supplier sites information.
Po_distributions_all
Some columns of interest includes :
 Purchase Orders > Purchase Orders
 Pay_site_flag
 Purchasing_site_flag This table stores the accounting information on a purchase
order shipment. This table is used for Standard and
 Address_line1 to address_line3 Planned Purchase Orders and Planned and Blanket
 City Purchase Order Release.
 State
Some columns of interest includes :
 Area_code
 Quantity_ordered
 Zip
 Quantity_billed
Po_headers_all
 Amount_billed
 Purchase Orders > Purchase Orders  Quantity_delivered
 Quantity_cancelled
This table stores the seven types of purchasing documents
such as Purchase Order and Blanket Agreement.  Destination_organization_id (link to
org_organization_definitions for the organization
Segment1 is the document number (i.e. purchase order code)
number)  Destination_subinventory

Some columns of interest includes : Rcv_shipment_headers

 Agent_id (link to per_people_f for the buyer)  Receiving > Receipts


 Type_lookup_code
This table stores the receiving information. The three
Po_lines_all receipt sources are Supplier, Inventory and Internal Order.
There is one receipt header per receipt source.
 Purchase Orders > Purchase Orders
Some columns of interest includes :
This table stores purchasing document lines.
 Receipt_num
Some columns of interest includes :  Shipment_num
 Line_num  Receipt_source_code
 Item_description  Shipped_date
 Unit_price  Ship_to_org_id
 Unit_meas_lookup_code (unit of measure) Rcv_shipment_lines
 Quantity
 Receiving > Receipts
 Item_id (link to mtl_system_items for the item
number) This table stores information about items that have been
 Category_id (link to mtl_categories for the category shipped and/or received from a receipt source.
name)
Some columns of interest includes :
Po_line_locations_all
 Line_num
 Purchase Orders > Purchase Orders

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
 Quantity_shipped Some columns of interest includes :
 Unit_of_measure  Transaction_date
 Item_id (link to mtl_system_items for item number)  Gl_batch_id
 To_organization_id (link to  Accounting_line_type
org_organization_definitions for organization code)
 Base_transaction_value
 To_subinventory
 Shipment_line_status_code (EXPECTED, FULLY Mtl_system_items
RECEIVED, PARTIALLY RECEIVED)
 Items > Master Items or Items > Organization Items
 Quantity_received
 Quantity_shipped This table stores the item definition. An item must exist in
an inventory organisation.
Oracle Inventory
Your item number is stored in the columns segment1 to
Org_organization_definitions segment20 depending on your application configuration.
If you have configured your items to have to segments
 Setup > Organizations > Parameters then you may be using segment1 and segment2

This view contains basic information on all inventory Some columns of interest includes :
organisations.
 Segment1 to segment20
Some columns of interest includes :  Description

 Organization_code  Invetory_item_flag

 Organization_name  Purchasing_item_flag

 Set_of_books_id (when you have more than one set of  Inventory_asset_flag


book, you’ll also need to link to gl_sets_of_books)  Stock_enabled_flag
 Inventory_enabled_flag  Invoiceable_item_flag
Mtl_secondary_inventories  Shippable_item_flag
 So_transaction_flag
 Setup > Organizations > Subinventories
 Mtl_transactions_enabled_flag
This table stores all subinventory information for an  Primary_unit_of_measure
inventory organisation.
Mtl_onhand_quantities
Some columns of interest includes :
 On-hand, Availability > On-hand Quantities
 Secondary_inventory_name
This table stores quantity on hand in a location for each
item.
 Description
Some columns of interest includes :
Mtl_material_transactions
 Date_received
 Transactions > Material Transactions (Inquiry)
 Transaction_quantity
This table stores all inventory transactions including cost  Subinventory_code
updates.
Cst_item_costs
Some columns of interest includes :
 Costs > Item Costs
 Transaction_quantity
This table stores the item cost information. Note that there
 Transaction_type_id
can be multiple costs per item and the actual cost is where
 Transaction_source_type_id the cost type is Frozen.
 Transaction_source_name
Some columns of interest includes :
Mtl_transaction_accounts
 Cost_type_id (link to cst_cost_types)
 Transactions > Material Distributions (Inquiry)
 Item_cost

This table stores the inventory accounting information.


There are two rows in this table for each transaction in Oracle Receivables
mtl_material_transactions. Ra_customers

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
 Customers > Standard  Trx_date (invoice date)

This table stores customer information. Ra_customer_trx_lines_all

 Transactions > Transactions


Some columns of interest includes :

 Customer_name This table stores the invoice, debit memo, chargeback,


commitment and credit memo line information.
 Customer_number
 Status Some columns of interest includes :
 Customer_prospect_code  Line_number
 Customer_type  Description
 Orig_system_reference (for imported customers from  Quantity_ordered
an external source)
 Quantity_credited
Ra_addresses_all
 Quantity_invoiced
 Customers > Standard  Unit_standard_price
 Unit_selling_price
This table stores customer address information and your
remit-to addresses.  Line_type
 Extended_amount
Some columns of interest includes :
 Revenue_amount
 Status
Ra_cust_trx_line_gl_dist_all
 Orig_system_reference (for imported customer
addresses from an external source)  Transactions > Transactions
 Address1 to address4
This table stores the accounting information for revenue,
 City unearned revenue, unbilled receivables, receivables,
 State charges, freight and tax for each invoice or credit memo
line.
 Postal_code

Ra_site_uses_all Some columns of interest includes :

 Customers > Standard  Amount_gl_date


 Gl_posted_date
This table stores the customer’s site and site purpose. You  Account_class
must have one row for each address. A customer must (CHARGES/FREIGHT/TAX/REC/REV/UNBILL/U
have one bill to address for Receivables. A customer must NEARN)
have one ship to address and one bill to address for Order
Entry.  Acctd_amount (functional currency)

Ar_cash_receipts
Some columns of interest includes :
 Receipts > Receipts
 Site_use_code (BILL_TO, SHIP_TO, STMTS,
DUN/LEGAL)
This table stores the payment information.
 Primary_flag
 Status Some columns of interest includes :
 Location  Set_of_books_id (when you have more than one set of
book, you’ll also need to link to gl_sets_of_books)
Ra_customer_trx_all
 Status (APP, UNAPP, UNID, NSF, STOP, REV)
 Transactions > Transactions
 Type (CASH, MISC)
This table stores invoice, debit memo, chargeback,  Receipt_number
commitment and credit memo header information.  Amount

Some columns of interest includes :  Currency_code


 Pay_from_customer
 Cust_trx_type_id (link to ra_cust_trx_types_all)
 Receipt_date
 Set_of_books_id (when you have more than one set of
book, you’ll also need to link to gl_sets_of_books) Ar_receivable_applications
 Terms_id (link to ra_terms)  Receipts > Receipts
 Trx_number (invoice number)

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
This table stores accounting entries for cash and credit So_lines_all
memo applications.
 Orders, Returns > Orders, Returns
Some columns of interest includes :
This table stores the orders and returns line information.
 Amount_applied
 Line_applied The s1 to s30 and s1_date to s30_date relates to the order
line cycle status.
 Tax_applied
 Application_type Some columns of interest includes :
 Display  Line_type_code (DETAIL, PARENT, REGULAR,
 Gl_date RETURN)
 Set_of_books_id (when you have more than one set of  Ordered_quantity
book, you’ll also need to link to gl_sets_of_books)  Cancelled_quantity
Ar_payment_schedules  Selling_price

 Transactions > Transactions and Receipts > Receipts  Price_list_id (links to so_price_lists for price list)
 Schedule_date
This table stores all transactions except adjustments and  Promise_date
miscellaneous cash receipts. This table is updated when a
transaction occurs against an invoice, debit memo, So_line_details
chargeback, credit memo, on-account credit, or receipt.
 Orders, Returns > Orders, Returns
Some columns of interest includes :
This table stores order scheduling information.
 Amount_due_original
 Status Some columns of interest includes :
 Class (DEP, DM, PMT, GUAR, CM, CB, INV)  Released_flag
 Due_date  Quantity
 Amount_due_remaining  Schedule_date
 Invoice_currency_code  Delivery (link to mtl_demand for reservation details)
 Amount_applied
So_picking_batches_all
 Anmount_credited
 Shipping > Release Sales Orders or Shipping >
 Amount_adjusted
Release Sales Orders, SRS

Oracle Order Entry This table stores the batch of orders that have been pick
released.
So_headers_all

 Orders, Returns > Orders, Returns The header_count column indicates the number of picking
headers are contained in a picking batch.
This table stores the orders and returns information.
So_picking_headers_all
The s1 to s30 and s1_date to s30_date relates to the order
 Shipping > Release Sales Orders or Shipping >
cycle status.
Release Sales Orders, SRS
Some columns of interest includes :
This table stores the picking headers within a picking
 Order_category (I, P. S, R, RMA) batch.

 Order_number Some columns of interest includes :


 Purchase_order_num
 Status_code (BACKORDERED, BACKORDER
 Original_system_source_code (for imported orders RELEASE, CLOSED, OPEN, PENDING, IN
from an external source) PROGRESS)
 Original_system_reference (for imported orders from  Pick_slip_number
an external source)
 Picked_by (link to per_people_f for picked by user)
 Order_type_id (link to so_order_types_all for order
type)  Date_released

 Date_ordered  Date_confirmed

 S1 to s30  Date_shipped

 S1_date to s30_date So_picking_lines_all

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
 Shipping > Release Sales Orders or Shipping >
Release Sales Orders, SRS

This table stores the picking lines for a picking header.

Some columns of interest includes :

 Requested_quantity
 shipped_quantity
 Date_requested
 Cancelled_quantity

So_picking_line_details

 Shipping > Release Sales Orders or Shipping >


Release Sales Orders, SRS

This table stores the location for the picking lines that have
been reserved.

Some columns of interest includes :

 Requested_quantity
 Serial_number

Wsh_departure

 Shipping > Departure Planning> Departure Planning


or Shipping > Departure Planning > New Departures

This table stores departure information for departure


planning.

Some columns of interest includes :

 Name
 Planned_departure_date
 Actual_depature_date

Wsh_delivery

 Shipping > Departure Planning> Departure Planning


or Shipping > Departure Planning > New Deliveries

This table stores delivery information within a departure.

Some columns of interest includes :

 Name
 Planned_departure_date
 Actual_depature_date
 Waybill
 Date_closed

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
o r g a n iz a t io n _ id t r a n s a c t io n _ id
GL1 G L2 IN V1 IN V3 IN V6
g l_ c o d e _ c o m b in a t io n s g l_ je _ b a t c h e s o r g _ o r g a n iz a t io n _ d e f in it io n s m t l_ m a t e r ia l_ t r a n s a c t io n s m t l_ t r a n s a c t io n _ a c c o u n t s

in v e n t o r y _ it e m _ id
j e _ b a t c h _ id o r g a n iz a t io n _ id s u b in v e n t o r y _ c o d e
o r g a n iz a t io n _ id
G L3 IN V2 IN V4 in v e n t o r y _ it e m _ id
g l_ je _ h e a d e r s m t l_ s e c o n d a r y _ in v e n t o r ie s m t l_ s y s t e m _ it e m s
o r g a n iz a t io n _ id
s e c o n d a r y _ in v e n t o r y _ n a m e in v e n t o r y _ it e m _ id
j e _ h e a d e r _ id
o r g a n iz a t io n _ id
G L4 IN V5 IN V7
c o d e _ c o m b in a t io n _ id g l_ j e _ lin e s m t l_ o n h a n d _ q u a n t it y c s t _ it e m _ c o s t s
G eneral Ledger Inventory
b ill_ t o _ c u s t o m e r _ id
c u s t o m e r _ id s h ip _ t o _ c u s t o m e r _ id
AR1 AR4 AR7 O E1 h e a d e r _ id O E4
ra_ custom ers r a _ c u s t o m e r _ t r x _ a ll a r _ c a s h _ r e c e ip t s s o _ h e a d e r s _ a ll s o _ p ic k in g _ b a t c h e s _ a ll

b ill_ t o _ s it e _ u s e _ id
c u s t o m e r _ id c u s t o m e r _ t r x _ id c a s h _ r e c e ip t _ id h e a d e r _ id b a t c h _ id
s h ip _ t o _ s it e _ u s e _ id
c u s t o m e r _ t r x _ id o r d e r _ h e a d e r _ id
AR2 AR5 AR8 O E2 O E5
r a _ a d d r e s s e s _ a ll r a _ c u s t o m e r _ t r x _ lin e s _ a ll a r _ r e c e iv a b le _ a p p lic a t io n s s o _ lin e s _ a ll s o _ p ic k in g _ h e a d e r s _ a ll
lin e _ id

a d d r e s s _ id c u s t o m e r _ t r x _ lin e _ id p a y m e n t _ s c h e d u le _ id lin e _ id p ic k in g _ h e a d e r _ id
o r d e r _ lin e _ id
AR3 A 1R 6 AR9 O E3 O E6 O E8
r a _ s it e _ u s e s _ a ll r a _ c u s t _ t r x _ lin e _ g l_ d is t _ a ll a r _ p a y m e n t _ s c h e d u le s s o _ lin e _ d e t a ils s o _ p ic k in g _ lin e s _ a ll w sh_ departure
s it e _ u s e _ id
lin e _ d e t a il_ id
d e p a r t u r e _ id
p ic k in g _ lin e _ id p la n n e d _ d e p a r t u r e _ id
a c t u a l_ d e p a r t u r e _ id
O E7 O E9
s o _ p ic k in g _ lin e _ d e t a ils w s h _ d e liv e r ie s
R e c e iv a b le s O rder E ntry

v e n d o r _ id
A P1 in v o ic e _ id A P3 PO 1 PO 3 PO 7
a p _ in v o ic e s _ a ll a p _ p a y m e n t _ s c h e d u le s _ a ll po_vendors p o _ h e a d e r s _ a ll r c v _ s h ip m e n t _ h e a d e r s

in v o ic e _ id v e n d o r _ id p o _ h e a d e r _ id s h ip m e n t _ h e a d e r _ id
in v o ic e _ id
A P2 A P4 PO 2 PO 4 PO 8
a p _ in v o ic e _ d is t r ib u t io n s _ a ll a p _ c h e c k s _ a ll p o _ v e n d o r _ s it e s _ a ll p o _ lin e s _ a ll r c v _ s h ip m e n t _ lin e s
v e n d o r _ s it e _ id
c h e c k _ id p o _ lin e _ id

A P5 PO 5
a p _ in v o ic e _ p a y m e n t s _ a ll p o _ lin e _ lo c a t io n s _ a ll

in v o ic e _ p a y m e n t _ id lin e _ lo c a t io n _ id

PO 6 p o _ d is t r ib u t io n _ id
A P6
a p _ in v o ic e _ d is t r ib u t io n s _ a ll P a y a b le s P u r c h a s in g p o _ d is t r ib u t io n s _ a ll

C r o s s A p p lic a t io n J o in s

GL1 c o d e _ c o m b in a t io n _ id = A R6, A R9 c o d e _ c o m b in a t io n _ id A P1 p o _ h e a d e r _ id = PO 3 p o _ h e a d e r _ id
PO 6
GL1 c o d e _ c o m b in a t io n _ id = PO 6 b u d g e t _ a c c o u n t _ id , a c c r u a l_ a c c o u n t _ id , A P6 p o _ d is t r ib u t io n _ id = PO 6 p o _ d is t r ib u t io n _ id
v a r ia n c e _ a c c o u n t _ id
GL 1 c o d e _ c o m b in a t io n _ id = IN V6 reference_accounts A P1 v e n d o r _ id = PO 1 v e n d o r _ id
GL 1 c o d e _ c o m b in a t io n _ id = A P2 , A P6 a c c t s _ p a y _ c o d e _ c o m b in a t io n _ id A P1 v e n d o r _ s it e _ id = PO 2 v e n d o r _ s it e _ id
GL 1 c o d e _ c o m b in a t io n _ id = A P6 d is t _ c o d e _ c o m b in a t io n _ id O E1 c u s t o m e r _ id = A R1 c u s t o m e r _ id
IN V3 s o u r c e _ lin e _ id = O E3 lin e _ d e t a il_ id O E1 s h ip _ t o _ s it e _ u s e _ id = A R2 s it e _ u s e _ id
a n d so urce _ c o d e = 'O R D E R E N T R Y ' a n d s it e _ u s e _ c o d e = ' S H I P _ T O '
IN V3 p ic k in g _ lin e _ id = O E6 p ic k in g _ lin e _ id O E1 b ill_ t o _ s it e _ u s e _ id = A R2 s it e _ is e _ id
a n d so urce _ c o d e = 'O R D E R E N T R Y ' a n d s it e _ u s e _ c o d e = ' B I L L _ T O '
IN V3 s h ip m e n t _ n u m b e r = PO 7 s h ip m e n t _ n u m AR5 in t e r f a c e _ lin e _ a t t r ib ute1 = O E1 order_num ber
a n d so urce _ c o d e = 'R C V ' a n d in t e r f a c e _ c o n t e x t = 'O R D E R E N T R Y '
IN V3 t r a n s a c t io n _ s o u r c e _ id = PO 8 s h ip m e n t _ lin e _ id AR5 in t e r f a c e _ lin e _ a t t r ib ute6 = O E2 lin e _ id
a n d so urce _ c o d e = 'R C V ' a n d in t e r f a c e _ c o n t e x t = 'O R D E R E N T R Y '
IN V4 o r g a n iz a t io n _ id = O E2 o r g a n iz a t io n _ id AR5 in t e r f a c e _ lin e _ a t t r ib ute7 = O E6 p ic k in g _ lin e _ id
IN V4 in v e n t o r y _ it e m _ id = O E2 , PO 4, in v e n t o r y _ it e m _ id a n d in t e r f a c e _ c o n t e x t = 'O R D E R E N T R Y '
A R5

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
Business Examples
To illustrate how important knowing the Oracle Applications data structure, I have included some business examples.

Reconciliation

Are you having problem reconciling your General Ledger to your subledger ? This process can take a long time to resolve if
you don’t know where to look.

The following SQL*Plus example displays the sum of the Trade Receipts from your Receivables subledger for a given period
name (i.e. ‘Apr-00’) by the General Ledger batch name. This example also assumes that you are entering receipts in batches.

You can even go further and look at the accounts for which these trade receipts have debited and credited by joining
ar_receivable_applications to the gl_code_combinations table via code_combination_id.

The gl_import_references table links the General Ledger journal tables to Receivables.
SELECT
Gb.name gl_batch_name,
B.name ar_batch,
NVL(SUM(DECODE(ra.status,'APP', ra.amount_applied,0)),0) +
NVL(SUM(DECODE(ra.status,'ACC', ra.amount_applied,0)),0) +
NVL(SUM(DECODE(ra.status,'UNAPP',ra.amount_applied,0)),0) +
NVL(SUM(DECODE(ra.status,'UNID', ra.amount_applied,0)),0) rec_amount
FROM ar_receivable_applications_all ra,
ar_cash_receipts_all cr,
ar_batches_all b,
ar_cash_receipt_history_all crh,
gl_je_batches gb
WHERE ra.cash_receipt_id = cr.cash_receipt_id
AND cr.cash_receipt_id = crh.cash_receipt_id
AND crh.batch_id = b.batch_id
AND (crh.batch_id, crh.cash_receipt_id, gb.je_batch_id) IN
(SELECT DISTINCT
ab.batch_id,
ac.cash_receipt_id,
b.je_batch_id
FROM
ar_batches_all ab,
ar_cash_receipt_history_all ah,
ar_cash_receipts_all ac,
gl_import_references i,
gl_je_headers h,
gl_je_batches b
WHERE h.je_header_id = i.je_header_id
AND b.je_batch_id = i.je_batch_id
AND i.reference_2 = ah.cash_receipt_id
AND ah.cash_receipt_id = ac.cash_receipt_id
AND ab.batch_id(+) = ah.batch_id
AND h.je_source = 'Receivables'
AND h.je_category = 'Trade Receipts'
AND h.je_batch_id = b.je_batch_id
AND h.period_name = 'Apr-00')
GROUP BY gb.name, b.name
ORDER BY 1, 2
/

Information Management

You schedule your orders but you are running low in stock for some items. The following example displays the reservation
information for the item parameter. Based on this information, you can then decide which orders can be rescheduled.

The table mtl_demand stores the reservation information and fnd_user contains user information. The majority of the tables
have the columns created_by, last_updated_by that represents the user who entered the transaction and the last user to have
updated the transaction, respectively.

SELECT DECODE(d.reservation_type, 1, 'On Demand', 2, 'Reserved') Res_type,


SUBSTR(u.user_name, 1, 20) User_name,
SUBSTR(i.segment1, 1, 10) Item,
c.customer_name cust_name,
c.customer_number cust_number,
h.order_number Ord_no,
substr(l.shipment_priority_code, 1, 10) ship_code,
h.date_ordered Date_ordered,
r.organization_code Org,
d.line_item_quantity demand_qty

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
FROM so_headers_all h,
mtl_demand d,
mtl_sales_orders s,
mtl_system_items i,
org_organization_definitions r,
fnd_user u,
ra_customers c,
so_lines_all l
WHERE h.created_by = u.user_id
AND d.inventory_item_id = i.inventory_item_id
AND d.organization_id = i.organization_id
AND h.order_number = s.segment1
AND r.organization_id = d.organization_id
AND c.customer_id = h.customer_id
AND d.demand_source_line = l.line_id
AND l.header_id = h.header_id
AND d.line_item_quantity > 0
AND i.segment1 BETWEEN '&&item_from' AND '&&item_to'
AND d.demand_id IN
(SELECT MAX(d1.demand_id)
FROM mtl_demand d1
WHERE d1.line_item_quantity > 0
AND d1.demand_source_type in (2, 8)
AND d1.parent_demand_id IS NOT NULL
GROUP BY d1.reservation_type, d1.parent_demand_id)
ORDER BY
DECODE(d.reservation_type, 1, 'Demand', 2, 'Reserved'),
SUBSTR(u.user_name, 1, 20),
SUBSTR(i.segment1, 1, 10)

Your customers have been returning products, but why ? Is it the product quality, is it the delivery ? How can the business
improve ?

You enter return reasons on Return Material Authorisations (RMAs) and the following example reviews the returns for a given
date range (where &&from_date and &&to_date are parameters in SQL*Plus) for when the RMAs have been created.

SELECT
l.transaction_reason_code reason_code,
c.customer_name cust_name,
SUBSTR(s.segment1, 1, 10) item,
h.order_number ord_no,
t.trx_number inv_no,
0 - NVL(l.ordered_quantity, 0) - NVL(l.cancelled_quantity, 0) rma_quantity,
NVL(tl.quantity_credited, 0) qty_credited,
NVL(tl.quantity_credited, 0) * NVL(unit_selling_price, 0) total_cr,
u.user_name creator_name,
h.creation_date creation_date
FROM fnd_user u,
mtl_system_items s,
ra_customers c,
ra_customer_trx_all t,
ra_customer_trx_lines_all tl,
so_headers_all h,
so_lines_all l
WHERE h.order_category = 'RMA'
AND h.cancelled_flag is null
AND tl.customer_trx_id = t.customer_trx_id(+)
AND tl.interface_line_attribute6(+) = l.line_id
AND c.customer_id = h.customer_id
AND u.user_id = h.created_by
AND l.inventory_item_id = s.inventory_item_id
AND l.warehouse_id = s.organization_id
AND h.header_id = l.header_id
AND h.creation_date between to_date('&&from_date', 'DD-MON-RRRR')
AND to_date('&&to_date', 'DD-MON-RRRR')
ORDER BY 1, 2
/

Alerts

You need to ensure that all orders entered for the day is booked in order to progress to the next step. Therefore, you may
setup an Oracle Alert based on the following SQL*Plus and email the output to the Sales Order Administrator. The following
can also highlight training issues if one particular user is not booking orders on a regular basis as indicated by the Created_by
column.

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved
SELECT
o.organization_code Org_name,
SUBSTR(msi.segment1, 1, 10) Item,
SUBSTR(msi.description, 1, 45) Item_desc,
sh.order_number Order_number,
sh.date_ordered Date_ordered,
SUBSTR(fu.user_name, 1, 12) Created_by,
NVL(sl.ordered_quantity, 0) - NVL(sl.cancelled_quantity, 0) Qty_ordered,
sl.selling_price*sl.ordered_quantity Ext_amount
FROM so_headers_all sh,
mtl_system_items msi,
so_lines_all sl,
fnd_user fu,
org_organization_definitions o
WHERE sh.header_id = sl.header_id
AND o.organization_id = msi.organization_id
AND sh.order_category IN ('R', 'RMA')
AND sl.inventory_item_id = msi.inventory_item_id
AND sl.warehouse_id = msi.organization_id
AND sh.created_by = fu.user_id
AND (sh.s1 = 5 or sh.s1 = 15)
AND sh.cancelled_flag is null
AND sh.creation_date BETWEEN TO_DATE('&&from_date, 'DD-MON-RR')
AND TO_DATE('&&to_date', 'DD-MON-RR')
ORDER BY
o.organization_code,
SUBSTR(msi.segment1, 1, 10),
SUBSTR(msi.description, 1, 45),
sh.order_number
/

About the Author

Jenny Chan is an Applications Consultant with Red Rock Consulting based in Sydney, Australia. She has 9 years experience
within the Oracle environment, 5 of which have been working with Oracle Applications. You can reach her by email at
chanj@redrock.net.au and there are web pages of articles and tips at http://www.redrock.net.au.

Copyright  2000, Red Rock Consulting Pty Ltd


All Rights Reserved

Anda mungkin juga menyukai