This chapter covers the following topics:
PL/SQL Package Name: HZ_CUST_ACCOUNT_SITE_V2PUB
Java Class Name: HzCustAccountSiteV2Pub
TYPE cust_acct_site_rec_type IS RECORD ( cust_acct_site_id NUMBER, cust_account_id NUMBER, party_site_id NUMBER, attribute_category VARCHAR2(30), attribute1 VARCHAR2(150), attribute2 VARCHAR2(150), attribute3 VARCHAR2(150), attribute4 VARCHAR2(150), attribute5 VARCHAR2(150), attribute6 VARCHAR2(150), attribute7 VARCHAR2(150), attribute8 VARCHAR2(150), attribute9 VARCHAR2(150), attribute10 VARCHAR2(150), attribute11 VARCHAR2(150), attribute12 VARCHAR2(150), attribute13 VARCHAR2(150), attribute14 VARCHAR2(150), attribute15 VARCHAR2(150), attribute16 VARCHAR2(150), attribute17 VARCHAR2(150), attribute18 VARCHAR2(150), attribute19 VARCHAR2(150), attribute20 VARCHAR2(150), global_attribute_category VARCHAR2(30), global_attribute1 VARCHAR2(150), global_attribute2 VARCHAR2(150), global_attribute3 VARCHAR2(150), global_attribute4 VARCHAR2(150), global_attribute5 VARCHAR2(150), global_attribute6 VARCHAR2(150), global_attribute7 VARCHAR2(150), global_attribute8 VARCHAR2(150), global_attribute9 VARCHAR2(150), global_attribute10 VARCHAR2(150), global_attribute11 VARCHAR2(150), global_attribute12 VARCHAR2(150), global_attribute13 VARCHAR2(150), global_attribute14 VARCHAR2(150), global_attribute15 VARCHAR2(150), global_attribute16 VARCHAR2(150), global_attribute17 VARCHAR2(150), global_attribute18 VARCHAR2(150), global_attribute19 VARCHAR2(150), global_attribute20 VARCHAR2(150), orig_system_reference VARCHAR2(240), orig_system VARCHAR2(30), status VARCHAR2(1), customer_category_code VARCHAR2(30), language VARCHAR2(4), key_account_flag VARCHAR2(1), tp_header_id NUMBER, ece_tp_location_code VARCHAR2(40), primary_specialist_id NUMBER, secondary_specialist_id NUMBER, territory_id NUMBER, territory VARCHAR2(30), translated_customer_name VARCHAR2(50), created_by_module VARCHAR2(150), application_id NUMBER org_id NUMBER )
TYPE cust_site_use_rec_type IS RECORD ( site_use_id NUMBER, cust_acct_site_id NUMBER, site_use_code VARCHAR2(30), primary_flag VARCHAR2(1), status VARCHAR2(1), location VARCHAR2(40), bill_to_site_use_id NUMBER, orig_system_reference VARCHAR2(240), orig_system VARCHAR2(30), sic_code VARCHAR2(30), payment_term_id NUMBER, gsa_indicator VARCHAR2(1), ship_via VARCHAR2(25), fob_point VARCHAR2(30), order_type_id NUMBER, price_list_id NUMBER, freight_term VARCHAR2(30), warehouse_id NUMBER, territory_id NUMBER, attribute_category VARCHAR2(30), attribute1 VARCHAR2(150), attribute2 VARCHAR2(150), attribute3 VARCHAR2(150), attribute4 VARCHAR2(150), attribute5 VARCHAR2(150), attribute6 VARCHAR2(150), attribute7 VARCHAR2(150), attribute8 VARCHAR2(150), attribute9 VARCHAR2(150), attribute10 VARCHAR2(150), tax_reference VARCHAR2(50), sort_priority NUMBER, tax_code VARCHAR2(50), attribute11 VARCHAR2(150), attribute12 VARCHAR2(150), attribute13 VARCHAR2(150), attribute14 VARCHAR2(150), attribute15 VARCHAR2(150), attribute16 VARCHAR2(150), attribute17 VARCHAR2(150), attribute18 VARCHAR2(150), attribute19 VARCHAR2(150), attribute20 VARCHAR2(150), attribute21 VARCHAR2(150), attribute22 VARCHAR2(150), attribute23 VARCHAR2(150), attribute24 VARCHAR2(150), attribute25 VARCHAR2(150), demand_class_code VARCHAR2(30), tax_header_level_flag VARCHAR2(1), tax_rounding_rule VARCHAR2(30), global_attribute1 VARCHAR2(150), global_attribute2 VARCHAR2(150), global_attribute3 VARCHAR2(150), global_attribute4 VARCHAR2(150), global_attribute5 VARCHAR2(150), global_attribute6 VARCHAR2(150), global_attribute7 VARCHAR2(150), global_attribute8 VARCHAR2(150), global_attribute9 VARCHAR2(150), global_attribute10 VARCHAR2(150), global_attribute11 VARCHAR2(150), global_attribute12 VARCHAR2(150), global_attribute13 VARCHAR2(150), global_attribute14 VARCHAR2(150), global_attribute15 VARCHAR2(150), global_attribute16 VARCHAR2(150), global_attribute17 VARCHAR2(150), global_attribute18 VARCHAR2(150), global_attribute19 VARCHAR2(150), global_attribute20 VARCHAR2(150), global_attribute_category VARCHAR2(30), primary_salesrep_id NUMBER, finchrg_receivables_trx_id NUMBER, dates_negative_tolerance NUMBER, dates_positive_tolerance NUMBER, date_type_preference VARCHAR2(20), over_shipment_tolerance NUMBER, under_shipment_tolerance NUMBER, item_cross_ref_pref VARCHAR2(30), over_return_tolerance NUMBER, under_return_tolerance NUMBER, ship_sets_include_lines_flag VARCHAR2(1), arrivalsets_include_lines_flag VARCHAR2(1), sched_date_push_flag VARCHAR2(1), invoice_quantity_rule VARCHAR2(30), gl_id_rec NUMBER, gl_id_rev NUMBER, gl_id_tax NUMBER, gl_id_freight NUMBER, gl_id_clearing NUMBER, gl_id_unbilled NUMBER, gl_id_unearned NUMBER, gl_id_unpaid_rec NUMBER, gl_id_remittance NUMBER, gl_id_factor NUMBER, tax_classification VARCHAR2(30), created_by_module VARCHAR2(150), application_id NUMBER )
public static class CustAcctSiteRec { public BigDecimal cust_acct_site_id; public BigDecimal cust_account_id; public BigDecimal party_site_id; public String attribute_category; public String attribute1; public String attribute2; public String attribute3; public String attribute4; public String attribute5; public String attribute6; public String attribute7; public String attribute8; public String attribute9; public String attribute10; public String attribute11; public String attribute12; public String attribute13; public String attribute14; public String attribute15; public String attribute16; public String attribute17; public String attribute18; public String attribute19; public String attribute20; public String global_attribute_category; public String global_attribute1; public String global_attribute2; public String global_attribute3; public String global_attribute4; public String global_attribute5; public String global_attribute6; public String global_attribute7; public String global_attribute8; public String global_attribute9; public String global_attribute10; public String global_attribute11; public String global_attribute12; public String global_attribute13; public String global_attribute14; public String global_attribute15; public String global_attribute16; public String global_attribute17; public String global_attribute18; public String global_attribute19; public String global_attribute20; public String orig_system_reference; public String orig_system; public String status; public String customer_category_code; public String language; public String key_account_flag; public BigDecimal tp_header_id; public String ece_tp_location_code; public BigDecimal primary_specialist_id; public BigDecimal secondary_specialist_id; public BigDecimal territory_id; public String territory; public String translated_customer_name; public String created_by_module; public BigDecimal application_id; public CustAcctSiteRec(); public CustAcctSiteRec(boolean __RosettaUseGMISSValues); } public CustAcctSiteRec(boolean __RosettaUseGMISSValues); }
public static class CustSiteUseRec { public BigDecimal site_use_id; public BigDecimal cust_acct_site_id; public String site_use_code; public String primary_flag; public String status; public String location; public BigDecimal bill_to_site_use_id; public String orig_system_reference; public String orig_system; public String sic_code; public BigDecimal payment_term_id; public String gsa_indicator; public String ship_via; public String fob_point; public BigDecimal order_type_id; public BigDecimal price_list_id; public String freight_term; public BigDecimal warehouse_id; public BigDecimal territory_id; public String attribute_category; public String attribute1; public String attribute2; public String attribute3; public String attribute4; public String attribute5; public String attribute6; public String attribute7; public String attribute8; public String attribute9; public String attribute10; public String tax_reference; public BigDecimal sort_priority; public String tax_code; public String attribute11; public String attribute12; public String attribute13; public String attribute14; public String attribute15; public String attribute16; public String attribute17; public String attribute18; public String attribute19; public String attribute20; public String attribute21; public String attribute22; public String attribute23; public String attribute24; public String attribute25; public String demand_class_code; public String tax_header_level_flag; public String tax_rounding_rule; public String global_attribute1; public String global_attribute2; public String global_attribute3; public String global_attribute4; public String global_attribute5; public String global_attribute6; public String global_attribute7; public String global_attribute8; public String global_attribute9; public String global_attribute10; public String global_attribute11; public String global_attribute12; public String global_attribute13; public String global_attribute14; public String global_attribute15; public String global_attribute16; public String global_attribute17; public String global_attribute18; public String global_attribute19; public String global_attribute20; public String global_attribute_category; public BigDecimal primary_salesrep_id; public BigDecimal finchrg_receivables_trx_id; public BigDecimal dates_negative_tolerance; public BigDecimal dates_positive_tolerance; public String date_type_preference; public BigDecimal over_shipment_tolerance; public BigDecimal under_shipment_tolerance; public String item_cross_ref_pref; public BigDecimal over_return_tolerance; public BigDecimal under_return_tolerance; public String ship_sets_include_lines_flag; public String arrivalsets_include_lines_flag; public String sched_date_push_flag; public String invoice_quantity_rule; public BigDecimal gl_id_rec; public BigDecimal gl_id_rev; public BigDecimal gl_id_tax; public BigDecimal gl_id_freight; public BigDecimal gl_id_clearing; public BigDecimal gl_id_unbilled; public BigDecimal gl_id_unearned; public BigDecimal gl_id_unpaid_rec; public BigDecimal gl_id_remittance; public BigDecimal gl_id_factor; public String tax_classification; public String created_by_module; public BigDecimal application_id; public CustSiteUseRec(); public CustSiteUseRec(boolean __RosettaUseGMISSValues); }
This routine is used to create a Customer Account Site. The API creates a record in the HZ_CUST_ACCT_SITES table. The customer account site is created using an existing customer account and an existing party site. If an orig_system_reference is passed in, the API creates a record in the HZ_ORIG_SYS_REFERENCES table to store the mapping between the source system reference and the TCA primary key. If orig_system_reference is not passed in, the default is UNKNOWN. When you use this API to create a new Customer Account Site, the status is inherited from the corresponding Party Site.
PROCEDURE create_cust_acct_site ( p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE, p_cust_acct_site_rec IN CUST_ACCT_SITE_REC_TYPE, x_cust_acct_site_id OUT NUMBER, x_return_status OUT VARCHAR2, x_msg_count OUT NUMBER, x_msg_data OUT VARCHAR2 )
public static void createCustAcctSite( OracleConnection_connection, String p_init_msg_list, CustAcctSiteRec p_cust_acct_site_rec, BigDecimal [ ] x_cust_acct_site_id, String [ ] x_return_status, BigDecimal [ ] x_msg_count, String [ ] x_msg_data ) throws SQLException;
The following table lists information about the parameters in the Create Customer Account Site API. The table includes the parameter names, the type of each parameter, the data type of each parameter, the necessity of the parameter, and other information about the parameter such as validation, defaults, and other comments.
Parameter Name | Type | Data Type | Required | Validation, Default, Comment |
---|---|---|---|---|
cust_acct_site_id | IN | NUMBER | Yes/No | Validation: unique if passed in, else generated from sequence |
cust_account_id | IN | NUMBER | Yes | Validation:
|
party_site_id | IN | NUMBER | Yes | Validation:
|
attribute_category | IN | VARCHAR2 | No | |
attribute1 | IN | VARCHAR2 | No | |
attribute2 | IN | VARCHAR2 | No | |
attribute3 | IN | VARCHAR2 | No | |
attribute4 | IN | VARCHAR2 | No | |
attribute5 | IN | VARCHAR2 | No | |
attribute6 | IN | VARCHAR2 | No | |
attribute7 | IN | VARCHAR2 | No | |
attribute8 | IN | VARCHAR2 | No | |
attribute9 | IN | VARCHAR2 | No | |
attribute10 | IN | VARCHAR2 | No | |
attribute11 | IN | VARCHAR2 | No | |
attribute12 | IN | VARCHAR2 | No | |
attribute13 | IN | VARCHAR2 | No | |
attribute14 | IN | VARCHAR2 | No | |
attribute15 | IN | VARCHAR2 | No | |
attribute16 | IN | VARCHAR2 | No | |
attribute17 | IN | VARCHAR2 | No | |
attribute18 | IN | VARCHAR2 | No | |
attribute19 | IN | VARCHAR2 | No | |
attribute20 | IN | VARCHAR2 | No | |
global_attribute_category | IN | VARCHAR2 | No | |
global_attribute1 | IN | VARCHAR2 | No | |
global_attribute2 | IN | VARCHAR2 | No | |
global_attribute3 | IN | VARCHAR2 | No | |
global_attribute4 | IN | VARCHAR2 | No | |
global_attribute5 | IN | VARCHAR2 | No | |
global_attribute6 | IN | VARCHAR2 | No | |
global_attribute7 | IN | VARCHAR2 | No | |
global_attribute8 | IN | VARCHAR2 | No | |
global_attribute9 | IN | VARCHAR2 | No | |
global_attribute10 | IN | VARCHAR2 | No | |
global_attribute11 | IN | VARCHAR2 | No | |
global_attribute12 | IN | VARCHAR2 | No | |
global_attribute13 | IN | VARCHAR2 | No | |
global_attribute14 | IN | VARCHAR2 | No | |
global_attribute15 | IN | VARCHAR2 | No | |
global_attribute16 | IN | VARCHAR2 | No | |
global_attribute17 | IN | VARCHAR2 | No | |
global_attribute18 | IN | VARCHAR2 | No | |
global_attribute19 | IN | VARCHAR2 | No | |
global_attribute20 | IN | VARCHAR2 | No | |
orig_system_reference | IN | VARCHAR2 | No | Validation: unique if passed in Default: cust_acct_site_id |
orig_system | IN | VARCHAR2 | No | Validation: Foreign key to HZ_ORIG_SYSTEMS.orig_system. Default: UNKNOWN if an orig_system_reference is passed in. |
status | IN | VARCHAR2 | No | Validation: status is lookup code in lookup type CODE_STATUS Default: A |
customer_category_code | IN | VARCHAR2 | No | Validation: customer_category_code is lookup code in lookup type ADDRESS_CATEGORY |
language | IN | VARCHAR2 | No | Comment: This parameter is no longer used. Use hz_locations.language instead. Validation: language is foreign key of fnd installed languages. |
key_account_flag | IN | VARCHAR2 | No | |
tp_header_id | IN | NUMBER | No | Validation: tp_header_id must be unique if pass in |
ece_tp_location_code | IN | VARCHAR2 | No | Validation: The ece_tp_location_code should be unique for a customer within the organization. |
primary_specialist_id | IN | NUMBER | No | Validation: primary_specialist_id is foreign key to per_all_people_f |
secondary_specialist_id | IN | NUMBER | No | Validation: secondary_specialist_id is foreign key to per_all_people_f |
territory_id | IN | NUMBER | No | |
territory | IN | VARCHAR2 | No | |
translated_customer_name | IN | VARCHAR2 | No | |
created_by_module | IN | VARCHAR2 | Yes | Validation: Mandatory attribute. Validated against AR lookup type HZ_CREATED_BY_MODULE. |
application_id | IN | NUMBER | No | Comment: Text to indicate module from which creation of record is initiated |
x_cust_acct_site_id | OUT | NUMBER | No | Comment: Returns cust_acct_site_id of the record created |
cust_account_id and party_site_id together should be unique for a particular organization.
Use this routine to update a Customer Account Site. The API updates records in the HZ_CUST_ACCT_SITES table.
If the primary key is not passed in, then get the primary key from the HZ_ORIG_SYS_REFERENCES table based on orig_system and orig_system_reference, which must be unique and cannot be null.
When you change the status of an existing Customer Account Site to Inactive, you also cause the status of the following to change to Inactive;
the corresponding Party Site
all Customer Account Sites associated with that Party Site
all Customer Account Site Uses for those Customer Account Sites
When you change the status of an existing Customer Account Site to Active, you also cause the status of the following to change to Active;
the corresponding Party Site
all Customer Account Sites associated with that Party Site
all Customer Account Site Uses for those Customer Account Sites
When you update a Customer Account Site, you also update the corresponding loc_assignment record in the HZ_LOC_ASSIGNMENTS table.
PROCEDURE update_cust_acct_site ( p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE, p_cust_acct_site_rec IN CUST_ACCT_SITE_REC_TYPE, p_object_version_number IN OUT NUMBER, x_return_status OUT VARCHAR2, x_msg_count OUT NUMBER, x_msg_data OUT VARCHAR2
public static void updateCustAcctSite( OracleConnection_connection, String p_init_msg_list, CustAcctSiteRec p_cust_acct_site_rec, BigDecimal [ ] p_object_version_number, String [ ] x_return_status, BigDecimal [ ] x_msg_count, String [ ] x_msg_data ) throws SQLException;
The following table lists information about the parameters in the Update Customer Account Site Organization API. The table includes the parameter names, the type of each parameter, the data type of each parameter, the necessity of the parameter, and other information about the parameter such as validation, defaults, and other comments.
Parameter Name | Type | Data Type | Required | Validation, Default, Comment |
---|---|---|---|---|
cust_acct_site_id | IN | NUMBER | Yes | Validation: valid cust_acct_site_id must be passed in Comment: Pass cust_acct_site_id from table hz_cust_acct_sites |
cust_account_id | IN | NUMBER | No | Validation: Not updateable |
party_site_id | IN | NUMBER | No | Validation: Not updateable |
attribute_category | IN | VARCHAR2 | No | |
attribute1 | IN | VARCHAR2 | No | |
attribute2 | IN | VARCHAR2 | No | |
attribute3 | IN | VARCHAR2 | No | |
attribute4 | IN | VARCHAR2 | No | |
attribute5 | IN | VARCHAR2 | No | |
attribute6 | IN | VARCHAR2 | No | |
attribute7 | IN | VARCHAR2 | No | |
attribute8 | IN | VARCHAR2 | No | |
attribute9 | IN | VARCHAR2 | No | |
attribute10 | IN | VARCHAR2 | No | |
attribute11 | IN | VARCHAR2 | No | |
attribute12 | IN | VARCHAR2 | No | |
attribute13 | IN | VARCHAR2 | No | |
attribute14 | IN | VARCHAR2 | No | |
attribute15 | IN | VARCHAR2 | No | |
attribute16 | IN | VARCHAR2 | No | |
attribute17 | IN | VARCHAR2 | No | |
attribute18 | IN | VARCHAR2 | No | |
attribute19 | IN | VARCHAR2 | No | |
attribute20 | IN | VARCHAR2 | No | |
global_attribute_category | IN | VARCHAR2 | No | |
global_attribute1 | IN | VARCHAR2 | No | |
global_attribute2 | IN | VARCHAR2 | No | |
global_attribute3 | IN | VARCHAR2 | No | |
global_attribute4 | IN | VARCHAR2 | No | |
global_attribute5 | IN | VARCHAR2 | No | |
global_attribute6 | IN | VARCHAR2 | No | |
global_attribute7 | IN | VARCHAR2 | No | |
global_attribute8 | IN | VARCHAR2 | No | |
global_attribute9 | IN | VARCHAR2 | No | |
global_attribute10 | IN | VARCHAR2 | No | |
global_attribute11 | IN | VARCHAR2 | No | |
global_attribute12 | IN | VARCHAR2 | No | |
global_attribute13 | IN | VARCHAR2 | No | |
global_attribute14 | IN | VARCHAR2 | No | |
global_attribute15 | IN | VARCHAR2 | No | |
global_attribute16 | IN | VARCHAR2 | No | |
global_attribute17 | IN | VARCHAR2 | No | |
global_attribute18 | IN | VARCHAR2 | No | |
global_attribute19 | IN | VARCHAR2 | No | |
global_attribute20 | IN | VARCHAR2 | No | |
orig_system_reference | IN | VARCHAR2 | No | Validation: Non updateable, but if a primary key is not passed in, you can pass in any ORIG_SYSTEM and ORIG_SYSTEM_REFERENCE that exists in the HZ_ORIG_SYS_REFERENCE table and unique validation is bypassed. The ORIG_SYSTEM_REFERENCE does not change, but persists in the table. |
orig_system | IN | VARCHAR2 | No | Foreign key to HZ_ORIG_SYSTEMS.orig_system. |
status | IN | VARCHAR2 | No | Validation:
|
customer_category_code | IN | VARCHAR2 | No | Validation: customer_category_code is lookup code in lookup type ADDRESS_CATEGORY |
language | IN | VARCHAR2 | No | Comment: This parameter is no longer used. Use hz_locations.language instead. Validation: language is foreign key of fnd installed languages. |
key_account_flag | IN | VARCHAR2 | No | |
tp_header_id | IN | NUMBER | No | Validation: tp_header_id must be unique |
ece_tp_location_code | IN | VARCHAR2 | No | |
primary_specialist_id | IN | NUMBER | No | Validation: primary_specialist_id is foreign key to per_all_people_f |
secondary_specialist_id | IN | NUMBER | No | Validation: secondary_specialist_id is foreign key to per_all_people_f |
territory_id | IN | NUMBER | No | |
territory | IN | VARCHAR2 | No | |
translated_customer_name | IN | VARCHAR2 | No | |
created_by_module | IN | VARCHAR2 | No | Validation: Non updateable if value exists, else validated against AR lookup type HZ_CREATED_BY_MODULE. |
application_id | IN | NUMBER | No | Validation: Not updateable if value exists |
p_object_version_number | IN OUT |
NUMBER | Yes | Validation:
Comment:
|
cust_account_id and party_site_id together should be unique for a particular organization.
This routine is used to create a Customer Account Site Use. The API creates a record in the HZ_CUST_SITE_USES table. Additionally profile information at site level can be created by this routine by passing proper value in p_create_profile. If an orig_system_reference is passed in, the API creates a record in the HZ_ORIG_SYS_REFERENCES table to store the mapping between the source system reference and the TCA primary key. If orig_system_reference is not passed in, the default is UNKNOWN.
The first active Customer Account Site Use that you create becomes the primary site use for every customer and organization combination. When you create a new active, primary Customer Account Site Use, the new Customer Account Site Use becomes the new primary site use.
PROCEDURE create_cust_site_use ( p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE, p_cust_site_use_rec IN CUST_SITE_USE_REC_TYPE, p_customer_profile_rec IN HZ_CUSTOMER_PROFILE_V2PUB.CUSTOMER_PROFILE_REC_TYPE, p_create_profile IN VARCHAR2:= FND_API.G_TRUE, p_create_profile_amt IN VARCHAR2:= FND_API.G_TRUE, x_site_use_id OUT NUMBER, x_return_status OUT VARCHAR2, x_msg_count OUT NUMBER, x_msg_data OUT VARCHAR2 )
Note: p_create_profile indicates whether to create customer profile for the site use being created. If value equals to FND_API.G_TRUE, a profile will be created. Similarly, p_create_profile_amt indicates whether to create profile amounts for the customer profile being created. If value equals to FND_API.G_TRUE, profile amounts will be created by copying over the profile amounts for the profile class on which this customer profile is based. p_create_profile_amt is processed only when p_create_profile equals to FND_API.G_TRUE.
public static void createCustSiteUse( OracleConnection_connection, String p_init_msg_list, CustSiteUseRec p_cust_site_use_rec, HzCustomerProfileV2Pub.CustomerProfileRec p_customer_profile_rec, String p_create_profile, String p_create_profile_amt, BigDecimal [ ] x_site_use_id, String [ ] x_return_status, BigDecimal [ ] x_msg_count, String [ ] x_msg_data ) throws SQLException;
Note: p_create_profile indicates whether to create customer profile for the site use being created. If value equals to HzConstant.getGTrue(), a profile will be created. Similarly, p_create_profile_amt indicates whether to create profile amounts for the customer profile being created. If value equals to HzConstant.getGTrue(), profile amounts will be created by copying over the profile amounts for the profile class on which this customer profile is based. p_create_profile_amt is processed only when p_create_profile equals to HzConstant.getGTrue().
The following table lists information about the parameters in the Create Customer Account Site Use API. The table includes the parameter names, the type of each parameter, the data type of each parameter, the necessity of the parameter, and other information about the parameter such as validation, defaults, and other comments.
Parameter Name | Type | Data Type | Required | Validation, Default, Comment |
---|---|---|---|---|
site_use_id | IN | NUMBER | Yes | Validation: unique if passed in, else generated from sequence |
cust_acct_site_id | IN | NUMBER | No | Validation:
|
site_use_code | IN | VARCHAR2 | No | Validation:
|
primary_flag | IN | VARCHAR2 | No | Validation: Primary_flag is lookup code in lookup type YES/NO Default: N |
status | IN | VARCHAR2 | No | Validation: status is lookup code in lookup type CODE_STATUS Default: A |
location | IN | VARCHAR2 | No | Validation:
|
bill_to_site_use_id | IN | NUMBER | No | |
orig_system_reference | IN | VARCHAR2 | No | Validation: site_use_id |
orig_system | IN | VARCHAR2 | No | Validation: Foreign key to HZ_ORIG_SYSTEMS.orig_system . Default: UNKNOWN if an orig_system_reference is passed in. |
sic_code | IN | VARCHAR2 | No | |
payment_term_id | IN | NUMBER | No | Validation: Must be a valid term_id from RA_TERMS |
gsa_indicator | IN | VARCHAR2 | No | Validation: gsa_indicator is lookup code in lookup type YES/NO Default: N |
ship_partial | IN | VARCHAR2 | No | Comment: This attribute is no longer used. Functionality replaced by ship_sets_include_lines_flag. |
ship_via | IN | VARCHAR2 | No | Validation: ship_via is foreign key to oe_ship_methods_v and can be used in both single and multi org case. |
fob_point | IN | VARCHAR2 | No | Validation: Validated against AR lookup type FOB. |
order_type_id | IN | NUMBER | No | Validation: Valid order_type_id from OE_ORDER_TYPES_V. |
price_list_id | IN | NUMBER | No | Validation: Valid price_list_id from SO_PRICE_LISTS. |
freight_term | IN | VARCHAR2 | No | Validation: freight_term is lookup code in lookup type FREIGHT_TERMS in so_lookups |
warehouse_id | IN | NUMBER | No | Validation: Valid organization_id from org_organization_definitions. |
territory_id | IN | NUMBER | No | |
attribute_category | IN | VARCHAR2 | No | |
attribute1 | IN | VARCHAR2 | No | |
attribute2 | IN | VARCHAR2 | No | |
attribute3 | IN | VARCHAR2 | No | |
attribute4 | IN | VARCHAR2 | No | |
attribute5 | IN | VARCHAR2 | No | |
attribute6 | IN | VARCHAR2 | No | |
attribute7 | IN | VARCHAR2 | No | |
attribute8 | IN | VARCHAR2 | No | |
attribute9 | IN | VARCHAR2 | No | |
attribute10 | IN | VARCHAR2 | No | |
tax_reference | IN | VARCHAR2 | No | |
sort_priority | IN | NUMBER | No | |
tax_code | IN | VARCHAR2 | No | Validation: Must be a valid tax_code from AR_VAT_TAX. |
attribute11 | IN | VARCHAR2 | No | |
attribute12 | IN | VARCHAR2 | No | |
attribute13 | IN | VARCHAR2 | No | |
attribute14 | IN | VARCHAR2 | No | |
attribute15 | IN | VARCHAR2 | No | |
attribute16 | IN | VARCHAR2 | No | |
attribute17 | IN | VARCHAR2 | No | |
attribute18 | IN | VARCHAR2 | No | |
attribute19 | IN | VARCHAR2 | No | |
attribute20 | IN | VARCHAR2 | No | |
attribute21 | IN | VARCHAR2 | No | |
attribute22 | IN | VARCHAR2 | No | |
attribute23 | IN | VARCHAR2 | No | |
attribute24 | IN | VARCHAR2 | No | |
attribute25 | IN | VARCHAR2 | No | |
demand_class_code | IN | VARCHAR2 | No | Validation: Validated against AR lookup type DEMAND_CLASS. |
tax_header_level_flag | IN | VARCHAR2 | No | |
tax_rounding_rule | IN | VARCHAR2 | No | |
global_attribute1 | IN | VARCHAR2 | No | |
global_attribute2 | IN | VARCHAR2 | No | |
global_attribute3 | IN | VARCHAR2 | No | |
global_attribute4 | IN | VARCHAR2 | No | |
global_attribute5 | IN | VARCHAR2 | No | |
global_attribute6 | IN | VARCHAR2 | No | |
global_attribute7 | IN | VARCHAR2 | No | |
global_attribute8 | IN | VARCHAR2 | No | |
global_attribute9 | IN | VARCHAR2 | No | |
global_attribute10 | IN | VARCHAR2 | No | |
global_attribute11 | IN | VARCHAR2 | No | |
global_attribute12 | IN | VARCHAR2 | No | |
global_attribute13 | IN | VARCHAR2 | No | |
global_attribute14 | IN | VARCHAR2 | No | |
global_attribute15 | IN | VARCHAR2 | No | |
global_attribute16 | IN | VARCHAR2 | No | |
global_attribute17 | IN | VARCHAR2 | No | |
global_attribute18 | IN | VARCHAR2 | No | |
global_attribute19 | IN | VARCHAR2 | No | |
global_attribute20 | IN | VARCHAR2 | No | |
global_attribute_category | IN | VARCHAR2 | No | |
primary_salesrep_id | IN | NUMBER | No | Validation: Valid salesrep_id from RA_SALESREPS. |
finchrg_receivables_trx_id | IN | NUMBER | No | Validation: Valid receivables_trx_id from AR_RECEIVABLES_TRX. |
dates_negative_tolerance | IN | NUMBER | No | |
dates_positive_tolerance | IN | NUMBER | No | |
date_type_preference | IN | VARCHAR2 | No | Validation: Validated against OE lookup type REQUEST_DATE_TYPE. |
over_shipment_tolerance | IN | NUMBER | No | |
under_shipment_tolerance | IN | NUMBER | No | |
item_cross_ref_pref | IN | VARCHAR2 | No | Validation: Allowed values are INT, CUST, and cross_reference_type value from MTL_CROSS_REFERENCE_TYPES. |
over_return_tolerance | IN | NUMBER | No | |
under_return_tolerance | IN | NUMBER | No | |
ship_sets_include_lines_flag | IN | VARCHAR2 | No | Validation:
Default: N |
arrivalsets_include_lines_flag | IN | VARCHAR2 | No | Validation:
Default: N |
sched_date_push_flag | IN | VARCHAR2 | No | Validation: sched_date_push_flag is lookup code in lookup type YES/NO Default: N |
invoice_quantity_rule | IN | VARCHAR2 | No | |
pricing_event | IN | VARCHAR2 | No | Comment: This attribute is no longer used. |
gl_id_rec | IN | NUMBER | No | Validation: gl_id_rec is valid gl field |
gl_id_rev | IN | NUMBER | No | Validation: gl_id_rev is valid gl field |
gl_id_tax | IN | NUMBER | No | Validation: gl_id_tax is valid gl field |
gl_id_freight | IN | NUMBER | No | Validation: gl_id_freight is valid gl field |
gl_id_clearing | IN | NUMBER | No | Validation: gl_id_clearing is valid gl field |
gl_id_unbilled | IN | NUMBER | No | Validation: gl_id_unbilled is valid gl field |
gl_id_unearned | IN | NUMBER | No | Validation: gl_id_unearned is valid gl field |
gl_id_unpaid_rec | IN | NUMBER | No | Validation: gl_id_unpaid_rec is valid gl field |
gl_id_remittance | IN | NUMBER | No | Validation: gl_id_remittance is valid gl field |
gl_id_factor | IN | NUMBER | No | Validation: gl_id_factor is valid gl field |
tax_classification | IN | VARCHAR2 | No | |
created_by_module | IN | VARCHAR2 | No | Validation: Mandatory attribute. Validated against AR lookup type HZ_CREATED_BY_MODULE. |
application_id | IN | NUMBER | No | Comment: Text to indicate application from which creation of record is initiated. |
p_create_profile | IN | VARCHAR2 | No | Validation: T or F Comment: If value T is passed, profile record for account site will be created. |
p_create_profile_amt | IN | VARCHAR2 | No | Validation: T or F Comment: If value T is passed, profile amount record for account site will be created. |
x_site_use_id | OUT | NUMBER | No | Comment: Returns site_use_id of the record created |
When creating a customer site use, if the site use code is also in PARTY_SITE_USE_CODE lookup type and the corresponding party site does not have such site use, which is active, the API internally creates party site use with the same site use code.
A customer can have only one active DUN, STMTS, LEGAL site use
cust_acct_site_id and site_use_code together should be unique.
For SHIP_TO site use, bill_to_site_use_id should be a valid active BILL_TO site use of one of an active account site of this account and its related account. For other type of site uses, this column should be null.
If site_use_code is not 'BILL_TO', then none of the gl_id_xxx fields should be populated.
This routine is used to update a Customer Account Site Use. The API updates a record in the HZ_CUST_SITE_USES table.
If the primary key is not passed in, then get the primary key from the HZ_ORIG_SYS_REFERENCES table based on orig_system and orig_system_reference if they are not null and unique.
If the primary flag is reset to Y for a new or existing Customer Account Site Use, then the existing primary Customer Account Site Use is reset to N.
PROCEDURE update_cust_site_use ( p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE, p_cust_site_use_rec IN CUST_SITE_USE_REC_TYPE, p_object_version_number IN OUT NUMBER, x_return_status OUT VARCHAR2, x_msg_count OUT NUMBER, x_msg_data OUT VARCHAR2 )
public static void updateCustSiteUse( OracleConnection_connection, String p_init_msg_list, CustSiteUseRec p_cust_site_use_rec, BigDecimal [ ] p_object_version_number, String [ ] x_return_status, BigDecimal [ ] x_msg_count, String [ ] x_msg_data ) throws SQLException;
The following table lists information about the parameters in the Update Customer Account Site Use API. The table includes the parameter names, the type of each parameter, the data type of each parameter, the necessity of the parameter, and other information about the parameter such as validation, defaults, and other comments.
Parameter Name | Type | Data Type | Required | Validation, Default, Comment |
---|---|---|---|---|
site_use_id | IN | NUMBER | Yes | Validation: valid site_use_id should be passed in Comment: Pass the site_use_id from hz_cust_site_uses table |
cust_acct_site_id | IN | NUMBER | Yes | Validation: Not updateable |
site_use_code | IN | VARCHAR2 | No | Validation: Not updateable |
primary_flag | IN | VARCHAR2 | No | Validation:
|
status | IN | VARCHAR2 | No | Validation:
|
location | IN | VARCHAR2 | No | Validation: Can only be updated if the AUTO_SITE_NUMBERING profile option in AR_SYSTEMS_PARAMETERS is unchecked. |
contact_id | IN | NUMBER | No | |
bill_to_site_use_id | IN | NUMBER | No | |
orig_system_reference | IN | VARCHAR2 | No | Validation: Non updateable, but if a primary key is not passed in, you can pass in any ORIG_SYSTEM and ORIG_SYSTEM_REFERENCE that exists in the HZ_ORIG_SYS_REFERENCE table and unique validation is bypassed. The ORIG_SYSTEM_REFERENCE does not change, but persists in the table. |
orig_system | IN | VARCHAR2 | No | Validation: Foreign key to HZ_ORIG_SYSTEMS.orig_system. |
sic_code | IN | VARCHAR2 | No | |
payment_term_id | IN | NUMBER | No | Validation: Must be a valid term_id from RA_TERMS. |
gsa_indicator | IN | VARCHAR2 | No | Validation: gsa_indicator is lookup code in lookup type YES/NO |
ship_partial | IN | VARCHAR2 | No | Comment: This attribute is no longer used. Functionality replaced by ship_sets_include_lines_flag. |
ship_via | IN | VARCHAR2 | No | Validation: ship_via is foreign key to oe_ship_methods_v and can be used in both single and multi org case. |
fob_point | IN | VARCHAR2 | No | Validation: Validated against AR lookup type FOB. |
order_type_id | IN | NUMBER | No | Validation: Valid order_type_id from OE_ORDER_TYPES_V. |
price_list_id | IN | NUMBER | No | Validation: Valid price_list_id from SO_PRICE_LISTS. |
freight_term | IN | VARCHAR2 | No | Validation: freight_term is lookup code in lookup type FREIGHT_TERMS in so_lookups |
warehouse_id | IN | NUMBER | No | Validation: Valid organization_id from ORG_ORGANIZATION_DEFINITIONS. |
territory_id | IN | NUMBER | No | |
attribute_category | IN | VARCHAR2 | No | |
attribute1 | IN | VARCHAR2 | No | |
attribute2 | IN | VARCHAR2 | No | |
attribute3 | IN | VARCHAR2 | No | |
attribute4 | IN | VARCHAR2 | No | |
attribute5 | IN | VARCHAR2 | No | |
attribute6 | IN | VARCHAR2 | No | |
attribute7 | IN | VARCHAR2 | No | |
attribute8 | IN | VARCHAR2 | No | |
attribute9 | IN | VARCHAR2 | No | |
attribute10 | IN | VARCHAR2 | No | |
tax_reference | IN | VARCHAR2 | No | |
sort_priority | IN | NUMBER | No | |
tax_code | IN | VARCHAR2 | No | Validation: Must be a valid tax_code from AR_VAT_TAX. |
attribute11 | IN | VARCHAR2 | No | |
attribute12 | IN | VARCHAR2 | No | |
attribute13 | IN | VARCHAR2 | No | |
attribute14 | IN | VARCHAR2 | No | |
attribute15 | IN | VARCHAR2 | No | |
attribute16 | IN | VARCHAR2 | No | |
attribute17 | IN | VARCHAR2 | No | |
attribute18 | IN | VARCHAR2 | No | |
attribute19 | IN | VARCHAR2 | No | |
attribute20 | IN | VARCHAR2 | No | |
attribute21 | IN | VARCHAR2 | No | |
attribute22 | IN | VARCHAR2 | No | |
attribute23 | IN | VARCHAR2 | No | |
attribute24 | IN | VARCHAR2 | No | |
attribute25 | IN | VARCHAR2 | No | |
demand_class_code | IN | VARCHAR2 | No | Validation: Validated against AR lookup type DEMAND_CLASS. |
tax_header_level_flag | IN | VARCHAR2 | No | |
tax_rounding_rule | IN | VARCHAR2 | No | |
global_attribute1 | IN | VARCHAR2 | No | |
global_attribute2 | IN | VARCHAR2 | No | |
global_attribute3 | IN | VARCHAR2 | No | |
global_attribute4 | IN | VARCHAR2 | No | |
global_attribute5 | IN | VARCHAR2 | No | |
global_attribute6 | IN | VARCHAR2 | No | |
global_attribute7 | IN | VARCHAR2 | No | |
global_attribute8 | IN | VARCHAR2 | No | |
global_attribute9 | IN | VARCHAR2 | No | |
global_attribute10 | IN | VARCHAR2 | No | |
global_attribute11 | IN | VARCHAR2 | No | |
global_attribute12 | IN | VARCHAR2 | No | |
global_attribute13 | IN | VARCHAR2 | No | |
global_attribute14 | IN | VARCHAR2 | No | |
global_attribute15 | IN | VARCHAR2 | No | |
global_attribute16 | IN | VARCHAR2 | No | |
global_attribute17 | IN | VARCHAR2 | No | |
global_attribute18 | IN | VARCHAR2 | No | |
global_attribute19 | IN | VARCHAR2 | No | |
global_attribute20 | IN | VARCHAR2 | No | |
global_attribute_category | IN | VARCHAR2 | No | |
primary_salesrep_id | IN | NUMBER | No | Validation: Valid salesrep_id from RA_SALESREPS. |
finchrg_receivables_trx_id | IN | NUMBER | No | Validation: Valid receivables_trx_id from AR_RECEIVABLES_TRX. |
dates_negative_tolerance | IN | NUMBER | No | |
dates_positive_tolerance | IN | NUMBER | No | |
date_type_preference | IN | VARCHAR2 | No | Validation: Validated against OE lookup type REQUEST_DATE_TYPE. |
over_shipment_tolerance | IN | NUMBER | No | |
under_shipment_tolerance | IN | NUMBER | No | |
item_cross_ref_pref | IN | VARCHAR2 | No | Validation: Allowed values are INT, CUST, and cross_reference_type value from MTL_CROSS_REFERENCE_TYPES. |
over_return_tolerance | IN | NUMBER | No | |
under_return_tolerance | IN | NUMBER | No | |
ship_sets_include_lines_flag | IN | VARCHAR2 | No | Validation:
|
arrivalsets_include_lines_flag | IN | VARCHAR2 | No | Validation:
|
sched_date_push_flag | IN | VARCHAR2 | No | Validation: sched_date_push_flag is lookup code in lookup type YES/NO |
invoice_quantity_rule | IN | VARCHAR2 | No | |
pricing_event | IN | VARCHAR2 | No | Comment: This attribute is no longer used. |
gl_id_rec | IN | NUMBER | No | Validation: gl_id_rec is valid gl field |
gl_id_rev | IN | NUMBER | No | Validation: gl_id_rev is valid gl field |
gl_id_tax | IN | NUMBER | No | Validation: gl_id_tax is valid gl field |
gl_id_freight | IN | NUMBER | No | Validation: gl_id_freight is valid gl field |
gl_id_clearing | IN | NUMBER | No | Validation: gl_id_clearing is valid gl field |
gl_id_unbilled | IN | NUMBER | No | Validation: gl_id_unbilled is valid gl field |
gl_id_unearned | IN | NUMBER | No | Validation: gl_id_unearned is valid gl field |
gl_id_unpaid_rec | IN | NUMBER | No | Validation: gl_id_unpaid_rec is valid gl field |
gl_id_remittance | IN | NUMBER | No | Validation: gl_id_remittance is valid gl field |
gl_id_factor | IN | NUMBER | No | Validation: gl_id_factor is valid gl field |
tax_classification | IN | VARCHAR2 | No | |
created_by_module | IN | VARCHAR2 | No | Validation: Non updateable if value exists, else validated against AR lookup type HZ_CREATED_BY_MODULE. |
application_id | IN | NUMBER | No | Validation: Not updateable if value exists |
p_object_version_number | IN/OUT | NUMBER | Yes | Validation:
Comment:
|
cust_acct_site_id and site_use_code together should be unique.