DBA Data[Home] [Help]

APPS.PO_R12_CAT_UPG_VAL_PVT dependencies on AP_TERMS

Line 2012: PROCEDURE get_ap_terms_name_from_id

2008: -- The outut name for the given ID.
2009: --OUT:
2010: --End of Comments
2011: --------------------------------------------------------------------------------
2012: PROCEDURE get_ap_terms_name_from_id
2013: (
2014: p_terms_id IN NUMBER,
2015: x_terms_name OUT NOCOPY VARCHAR2
2016: )

Line 2018: l_api_name CONSTANT VARCHAR2(30) := 'get_ap_terms_name_from_id';

2014: p_terms_id IN NUMBER,
2015: x_terms_name OUT NOCOPY VARCHAR2
2016: )
2017: IS
2018: l_api_name CONSTANT VARCHAR2(30) := 'get_ap_terms_name_from_id';
2019: l_log_head CONSTANT VARCHAR2(100) := g_module_prefix || l_api_name;
2020: l_progress VARCHAR2(3) := '000';
2021: BEGIN
2022: l_progress := '010';

Line 2033: FROM AP_TERMS_TL

2029: l_progress := '020';
2030: BEGIN
2031: SELECT name
2032: INTO x_terms_name
2033: FROM AP_TERMS_TL
2034: WHERE term_id = p_terms_id
2035: AND language = userenv('LANG');
2036: EXCEPTION
2037: WHEN OTHERS THEN

Line 2039: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'Exception while getting name from AP_TERMS_TL: '||SQLERRM); END IF;

2035: AND language = userenv('LANG');
2036: EXCEPTION
2037: WHEN OTHERS THEN
2038: l_progress := '030';
2039: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'Exception while getting name from AP_TERMS_TL: '||SQLERRM); END IF;
2040:
2041: x_terms_name := p_terms_id;
2042: END;
2043: -- ECO bug 5584556: End

Line 2054: END get_ap_terms_name_from_id;

2050: EXCEPTION
2051: WHEN OTHERS THEN
2052: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'Unexpected exception'); END IF;
2053: RAISE_APPLICATION_ERROR(g_err_num,l_log_head||','||l_progress || ','|| SQLERRM);
2054: END get_ap_terms_name_from_id;
2055:
2056: --------------------------------------------------------------------------------
2057: --Start of Comments
2058: --Name: validate_terms_id

Line 2067: -- Validates terms_id against AP_TERMS.

2063: -- b) FND_MSG_PUB on unhandled exceptions.
2064: --Locks:
2065: -- None.
2066: --Function:
2067: -- Validates terms_id against AP_TERMS.
2068: --Parameters:
2069: --IN:
2070: --p_key
2071: -- Key used to access records in PO_SESSION_GT table.

Line 2099: l_terms_name AP_TERMS_TL.name%TYPE;

2095: l_index NUMBER;
2096: i NUMBER;
2097: l_subscript_array PO_R12_CAT_UPG_TYPES.PO_TBL_NUMBER;
2098:
2099: l_terms_name AP_TERMS_TL.name%TYPE;
2100: BEGIN
2101: l_progress := '010';
2102: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'START'); END IF;
2103: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'Validating a defaulted field -- SHIP_VIA_LOOKUP_CODE (freight_carrier)'); END IF;

Line 2114: -- SQL What: Bulk validate terms_id against AP_TERMS.

2110: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'p_headers_rec.has_errors(1)='||p_headers_rec.has_errors(1)); END IF;
2111: END IF;
2112:
2113: l_progress := '020';
2114: -- SQL What: Bulk validate terms_id against AP_TERMS.
2115: -- Get the errored rows into GT table.
2116: -- SQL Why : It will be used to mark the record in plsql table as error.
2117: -- SQL Join: ship_via_lookup_code
2118: FORALL i IN 1 .. p_headers_rec.terms_id.COUNT

Line 2133: FROM AP_TERMS APT

2129: p_headers_rec.action(i) = PO_R12_CAT_UPG_PVT.g_action_header_create --Bug#5018883
2130: AND p_headers_rec.terms_id(i) IS NOT NULL
2131: AND NOT EXISTS
2132: (SELECT 1
2133: FROM AP_TERMS APT
2134: WHERE p_headers_rec.terms_id(i) = APT.term_id
2135: AND sysdate BETWEEN
2136: nvl(APT.start_date_active, sysdate - 1) AND
2137: nvl(APT.end_date_active, sysdate + 1));

Line 2161: get_ap_terms_name_from_id

2157: p_headers_rec.has_errors(l_index) := 'Y';
2158:
2159: -- ECO bug 5584556: convert id to name
2160: l_progress := '050';
2161: get_ap_terms_name_from_id
2162: (
2163: p_terms_id => l_err_terms_id_list(i)
2164: , x_terms_name => l_terms_name
2165: );

Line 2250: -- SQL What: Bulk validate shipping_control against AP_TERMS.

2246: IF g_debug THEN PO_R12_CAT_UPG_DEBUG.log_stmt(l_log_head,l_progress,'p_headers_rec.has_errors(1)='||p_headers_rec.has_errors(1)); END IF;
2247: END IF;
2248:
2249: l_progress := '020';
2250: -- SQL What: Bulk validate shipping_control against AP_TERMS.
2251: -- Get the errored rows into GT table.
2252: -- SQL Why : It will be used to mark the record in plsql table as error.
2253: -- SQL Join: ship_via_lookup_code
2254: FORALL i IN 1 .. p_headers_rec.shipping_control.COUNT