1: Package Body hxc_hph_bus as
2: /* $Header: hxchphrhi.pkb 120.2.12000000.2 2007/03/16 13:22:54 rchennur noship $ */
3: --
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
4: -- ----------------------------------------------------------------------------
5: -- | Private Global Definitions |
6: -- ----------------------------------------------------------------------------
7: --
8: g_package varchar2(33) := ' hxc_hph_bus.'; -- Global package name
9: g_debug boolean := hr_utility.debug_enabled;
10: --
11: -- The following two global variables are only to be
12: -- used by the return_legislation_code function.
128: ,p_argument => 'pref_hierarchy_id'
129: ,p_argument_value => p_pref_hierarchy_id
130: );
131: --
132: if ( nvl(hxc_hph_bus.g_pref_hierarchy_id, hr_api.g_number)
133: = p_pref_hierarchy_id) then
134: --
135: -- The legislation code has already been found with a previous
136: -- call to this function. Just return the value in the global
135: -- The legislation code has already been found with a previous
136: -- call to this function. Just return the value in the global
137: -- variable.
138: --
139: l_legislation_code := hxc_hph_bus.g_legislation_code;
140: if g_debug then
141: hr_utility.set_location(l_proc, 20);
142: end if;
143: else
163: -- Set the global variables so the values are
164: -- available for the next call to this function.
165: --
166: close csr_leg_code;
167: hxc_hph_bus.g_pref_hierarchy_id := p_pref_hierarchy_id;
168: hxc_hph_bus.g_legislation_code := l_legislation_code;
169: end if;
170: if g_debug then
171: hr_utility.set_location(' Leaving:'|| l_proc, 40);
164: -- available for the next call to this function.
165: --
166: close csr_leg_code;
167: hxc_hph_bus.g_pref_hierarchy_id := p_pref_hierarchy_id;
168: hxc_hph_bus.g_legislation_code := l_legislation_code;
169: end if;
170: if g_debug then
171: hr_utility.set_location(' Leaving:'|| l_proc, 40);
172: end if;
748: SELECT 'x'
749: FROM hxc_pref_hierarchies hph
750: WHERE hph.attribute_category = p_pref_code
751: and hph.pref_hierarchy_id <> p_pref_hierarchy_id
752: START WITH hph.parent_pref_hierarchy_id = hxc_hph_bus.get_top_level_id(p_parent_pref_hierarchy_id)
753: CONNECT BY PRIOR hph.pref_hierarchy_id = hph.parent_pref_hierarchy_id);
754:
755: CURSOR csr_chk_code2 IS
756: SELECT 'error'
1764: chk_legislation_code
1765: (p_business_group_id => p_rec.business_group_id,
1766: p_legislation_code => p_rec.legislation_code);
1767: --
1768: hxc_hph_bus.chk_df(p_rec);
1769: --
1770: hxc_hph_bus.validate_alias(p_rec);
1771: if g_debug then
1772: hr_utility.set_location(' Leaving:'||l_proc, 10);
1766: p_legislation_code => p_rec.legislation_code);
1767: --
1768: hxc_hph_bus.chk_df(p_rec);
1769: --
1770: hxc_hph_bus.validate_alias(p_rec);
1771: if g_debug then
1772: hr_utility.set_location(' Leaving:'||l_proc, 10);
1773: end if;
1774: End insert_validate;
1886: chk_legislation_code
1887: (p_business_group_id => p_rec.business_group_id,
1888: p_legislation_code => p_rec.legislation_code);
1889: --
1890: hxc_hph_bus.chk_df(p_rec);
1891: hxc_hph_bus.validate_alias(p_rec);
1892: --
1893: if g_debug then
1894: hr_utility.set_location(' Leaving:'||l_proc, 15);
1887: (p_business_group_id => p_rec.business_group_id,
1888: p_legislation_code => p_rec.legislation_code);
1889: --
1890: hxc_hph_bus.chk_df(p_rec);
1891: hxc_hph_bus.validate_alias(p_rec);
1892: --
1893: if g_debug then
1894: hr_utility.set_location(' Leaving:'||l_proc, 15);
1895: end if;
1917: hr_utility.set_location(' Leaving:'||l_proc, 10);
1918: end if;
1919: End delete_validate;
1920: --
1921: end hxc_hph_bus;