DBA Data[Home] [Help]

APPS.ZX_TCM_COMPOUND_PKG dependencies on ZX_TAX_RELATIONS_T

Line 13: INTO zx_tax_relations_t

9: -- branch
10: -- check for same regime, it could be two diff intos
11: -- check if both are branches
12: WHEN (same_branch='Y') THEN
13: INTO zx_tax_relations_t
14: (parent_tax_code_id ,
15: parent_tax_code ,
16: parent_regime_code ,
17: parent_precedence ,

Line 68: INTO zx_tax_relations_t

64: WHERE group_compound.tax_group_id = rel_tax_group_id
65: AND trunc (group_compound.compounding_precedence) <> group_compound.compounding_precedence
66: )
67: ) THEN
68: INTO zx_tax_relations_t
69: (parent_tax_code_id ,
70: parent_tax_code ,
71: parent_regime_code ,
72: parent_precedence ,

Line 190: DELETE FROM zx_tax_relations_t d

186:
187:
188: -- remove conflicting groups
189: -- logic is to assume duplicate rows by having a calculated id
190: DELETE FROM zx_tax_relations_t d
191: WHERE d.ROWID IN
192: ( SELECT min(a.ROWID)
193: FROM zx_tax_relations_t a,
194: zx_tax_relations_t b

Line 193: FROM zx_tax_relations_t a,

189: -- logic is to assume duplicate rows by having a calculated id
190: DELETE FROM zx_tax_relations_t d
191: WHERE d.ROWID IN
192: ( SELECT min(a.ROWID)
193: FROM zx_tax_relations_t a,
194: zx_tax_relations_t b
195: WHERE a.org_id = b.org_id
196: AND a.parent_tax_code = b.child_tax_code
197: AND b.parent_tax_code = a.child_tax_code

Line 194: zx_tax_relations_t b

190: DELETE FROM zx_tax_relations_t d
191: WHERE d.ROWID IN
192: ( SELECT min(a.ROWID)
193: FROM zx_tax_relations_t a,
194: zx_tax_relations_t b
195: WHERE a.org_id = b.org_id
196: AND a.parent_tax_code = b.child_tax_code
197: AND b.parent_tax_code = a.child_tax_code
198: GROUP BY a.parent_tax_code_id + a.child_tax_code_id, a.tax_group_id+b.tax_group_id);

Line 211: FROM zx_tax_relations_t a

207: SELECT tax_group_id, grp.tax_code group_code,
208: ROWNUM, 'Conflicting priority group '
209: FROM ar_vat_tax_all grp,
210: (SELECT min(a.tax_group_id) tax_group_id
211: FROM zx_tax_relations_t a
212: , zx_tax_relations_t b
213: WHERE a.org_id = b.org_id
214: AND a.parent_tax_code = b.child_tax_code
215: AND b.parent_tax_code = a.child_tax_code

Line 212: , zx_tax_relations_t b

208: ROWNUM, 'Conflicting priority group '
209: FROM ar_vat_tax_all grp,
210: (SELECT min(a.tax_group_id) tax_group_id
211: FROM zx_tax_relations_t a
212: , zx_tax_relations_t b
213: WHERE a.org_id = b.org_id
214: AND a.parent_tax_code = b.child_tax_code
215: AND b.parent_tax_code = a.child_tax_code
216: GROUP BY a.tax_group_id+b.tax_group_id )

Line 219: DELETE FROM zx_tax_relations_t d

215: AND b.parent_tax_code = a.child_tax_code
216: GROUP BY a.tax_group_id+b.tax_group_id )
217: WHERE tax_group_id = grp.vat_tax_id;
218:
219: DELETE FROM zx_tax_relations_t d
220: WHERE d.tax_group_id IN
221: ( SELECT min(a.tax_group_id)
222: FROM zx_tax_relations_t a, zx_tax_relations_t b
223: WHERE a.org_id = b.org_id

Line 222: FROM zx_tax_relations_t a, zx_tax_relations_t b

218:
219: DELETE FROM zx_tax_relations_t d
220: WHERE d.tax_group_id IN
221: ( SELECT min(a.tax_group_id)
222: FROM zx_tax_relations_t a, zx_tax_relations_t b
223: WHERE a.org_id = b.org_id
224: AND a.parent_tax_code = b.child_tax_code
225: AND b.parent_tax_code = a.child_tax_code
226: GROUP BY a.tax_group_id+b.tax_group_id);

Line 228: DELETE FROM zx_tax_relations_t a1

224: AND a.parent_tax_code = b.child_tax_code
225: AND b.parent_tax_code = a.child_tax_code
226: GROUP BY a.tax_group_id+b.tax_group_id);
227:
228: DELETE FROM zx_tax_relations_t a1
229: WHERE EXISTS (SELECT 1 FROM zx_tax_relations_t a2
230: WHERE a1.CHILD_TAX_CODE_ID = a2.CHILD_TAX_CODE_ID
231: AND a2.CHILD_PRECEDENCE = a1.CHILD_PRECEDENCE
232: AND a2.PARENT_TAX_CODE_ID <> a1.PARENT_TAX_CODE_ID

Line 229: WHERE EXISTS (SELECT 1 FROM zx_tax_relations_t a2

225: AND b.parent_tax_code = a.child_tax_code
226: GROUP BY a.tax_group_id+b.tax_group_id);
227:
228: DELETE FROM zx_tax_relations_t a1
229: WHERE EXISTS (SELECT 1 FROM zx_tax_relations_t a2
230: WHERE a1.CHILD_TAX_CODE_ID = a2.CHILD_TAX_CODE_ID
231: AND a2.CHILD_PRECEDENCE = a1.CHILD_PRECEDENCE
232: AND a2.PARENT_TAX_CODE_ID <> a1.PARENT_TAX_CODE_ID
233: AND a2.PARENT_PRECEDENCE > a1.PARENT_PRECEDENCE

Line 428: FROM zx_tax_relations_t

424:
425: CURSOR c_get_taxes_relation IS
426: SELECT org_id, parent_regime_code, parent_precedence, parent_tax_code_id,
427: child_regime_code, child_precedence
428: FROM zx_tax_relations_t
429: WHERE child_tax_code_id = v_child_tax
430: AND org_id = v_child_org;
431:
432:

Line 568: DELETE zx_tax_relations_t;

564: BEGIN
565:
566:
567:
568: DELETE zx_tax_relations_t;
569: DELETE zx_tax_priorities_t;
570: DELETE zx_compound_errors_t;
571: COMMIT;
572: