42: p_context IN VARCHAR2,
43: p_territory_code IN VARCHAR2,
44: x_ret_status OUT NOCOPY VARCHAR2
45: ) IS
46: l_descriptive_flexfield_name fnd_descr_flex_contexts_vl.descriptive_flexfield_name%TYPE;
47: l_context fnd_descr_flex_contexts_vl.descriptive_flex_context_code%TYPE;
48: l_application_id NUMBER;
49: BEGIN
50: IF UPPER(p_location_table_name) = 'HR_LOCATIONS_ALL' THEN
43: p_territory_code IN VARCHAR2,
44: x_ret_status OUT NOCOPY VARCHAR2
45: ) IS
46: l_descriptive_flexfield_name fnd_descr_flex_contexts_vl.descriptive_flexfield_name%TYPE;
47: l_context fnd_descr_flex_contexts_vl.descriptive_flex_context_code%TYPE;
48: l_application_id NUMBER;
49: BEGIN
50: IF UPPER(p_location_table_name) = 'HR_LOCATIONS_ALL' THEN
51: l_descriptive_flexfield_name := 'Address Location';
71:
72: BEGIN
73: SELECT descriptive_flex_context_code
74: INTO l_context
75: FROM fnd_descr_flex_contexts_vl
76: WHERE application_id = l_application_id
77: AND descriptive_flexfield_name = l_descriptive_flexfield_name
78: AND descriptive_flex_context_code = p_context;
79: