DBA Data[Home] [Help]

APPS.ZX_TRD_SERVICES_PUB_PKG dependencies on ZX_LINES

Line 51: p_tax_line_rec IN zx_lines%ROWTYPE,

47: p_index IN NUMBER,
48: x_return_status OUT NOCOPY VARCHAR2);
49:
50: PROCEDURE insert_item_dist(
51: p_tax_line_rec IN zx_lines%ROWTYPE,
52: x_return_status OUT NOCOPY VARCHAR2);
53:
54: PROCEDURE insert_global_table(
55: p_rec_nrec_dist_tbl IN OUT NOCOPY rec_nrec_dist_tbl_type,

Line 106: c_trx_line_id zx_lines.trx_line_id%TYPE,

102: p_event_class_rec IN ZX_API_PUB.event_class_rec_type,
103: x_return_status OUT NOCOPY VARCHAR2) IS
104:
105: CURSOR get_item_dist_csr(
106: c_trx_line_id zx_lines.trx_line_id%TYPE,
107: c_trx_level_type zx_lines.trx_level_type%TYPE) IS
108: SELECT /*+ INDEX(ZX_ITM_DISTRIBUTIONS_GT ZX_ITM_DISTRIBUTIONS_GT_U1 ZX_ITM_DISTRIBUTIONS_GT_U1) */
109: trx_line_dist_id,
110: trx_line_id,

Line 107: c_trx_level_type zx_lines.trx_level_type%TYPE) IS

103: x_return_status OUT NOCOPY VARCHAR2) IS
104:
105: CURSOR get_item_dist_csr(
106: c_trx_line_id zx_lines.trx_line_id%TYPE,
107: c_trx_level_type zx_lines.trx_level_type%TYPE) IS
108: SELECT /*+ INDEX(ZX_ITM_DISTRIBUTIONS_GT ZX_ITM_DISTRIBUTIONS_GT_U1 ZX_ITM_DISTRIBUTIONS_GT_U1) */
109: trx_line_dist_id,
110: trx_line_id,
111: trx_level_type,

Line 163: c_trx_line_id zx_lines.trx_line_id%TYPE,

159: AND trx_line_id = c_trx_line_id
160: AND trx_level_type = c_trx_level_type;
161:
162: CURSOR get_pseuso_line_info_csr(
163: c_trx_line_id zx_lines.trx_line_id%TYPE,
164: c_trx_level_type zx_lines.trx_level_type%TYPE) IS
165: SELECT trx_line_id,
166: trx_level_type,
167: line_intended_use,

Line 164: c_trx_level_type zx_lines.trx_level_type%TYPE) IS

160: AND trx_level_type = c_trx_level_type;
161:
162: CURSOR get_pseuso_line_info_csr(
163: c_trx_line_id zx_lines.trx_line_id%TYPE,
164: c_trx_level_type zx_lines.trx_level_type%TYPE) IS
165: SELECT trx_line_id,
166: trx_level_type,
167: line_intended_use,
168: line_amt,

Line 192: FROM zx_lines_det_factors

188: -- adjusted_doc_line_id,
189: -- applied_from_trx_level_type,
190: -- adjusted_doc_trx_level_type,
191: nvl(trx_line_gl_date, trx_date) -- item dist gl date
192: FROM zx_lines_det_factors
193: WHERE application_id = p_event_class_rec.application_id
194: AND event_class_code = p_event_class_rec.event_class_code
195: AND entity_code = p_event_class_rec.entity_code
196: AND trx_id = p_event_class_rec.trx_id

Line 259: l_old_trx_line_id zx_lines.trx_line_id%TYPE;

255: l_tax_line_tbl tax_line_tbl_type;
256: tax_line_counter NUMBER;
257:
258: l_counter NUMBER;
259: l_old_trx_line_id zx_lines.trx_line_id%TYPE;
260: l_old_trx_level_type zx_lines.trx_level_type%TYPE;
261: l_trx_line_id zx_lines.trx_line_id%TYPE;
262: l_trx_level_type zx_lines.trx_level_type%TYPE;
263: l_rec_nrec_dist_tbl rec_nrec_dist_tbl_type;

Line 260: l_old_trx_level_type zx_lines.trx_level_type%TYPE;

256: tax_line_counter NUMBER;
257:
258: l_counter NUMBER;
259: l_old_trx_line_id zx_lines.trx_line_id%TYPE;
260: l_old_trx_level_type zx_lines.trx_level_type%TYPE;
261: l_trx_line_id zx_lines.trx_line_id%TYPE;
262: l_trx_level_type zx_lines.trx_level_type%TYPE;
263: l_rec_nrec_dist_tbl rec_nrec_dist_tbl_type;
264:

Line 261: l_trx_line_id zx_lines.trx_line_id%TYPE;

257:
258: l_counter NUMBER;
259: l_old_trx_line_id zx_lines.trx_line_id%TYPE;
260: l_old_trx_level_type zx_lines.trx_level_type%TYPE;
261: l_trx_line_id zx_lines.trx_line_id%TYPE;
262: l_trx_level_type zx_lines.trx_level_type%TYPE;
263: l_rec_nrec_dist_tbl rec_nrec_dist_tbl_type;
264:
265: -- begin and end index for tax distribution for the same tax line and item dist

Line 262: l_trx_level_type zx_lines.trx_level_type%TYPE;

258: l_counter NUMBER;
259: l_old_trx_line_id zx_lines.trx_line_id%TYPE;
260: l_old_trx_level_type zx_lines.trx_level_type%TYPE;
261: l_trx_line_id zx_lines.trx_line_id%TYPE;
262: l_trx_level_type zx_lines.trx_level_type%TYPE;
263: l_rec_nrec_dist_tbl rec_nrec_dist_tbl_type;
264:
265: -- begin and end index for tax distribution for the same tax line and item dist
266: l_rec_nrec_dist_begin_index NUMBER;

Line 322: -- call TRL service to update Item_Dist_Changed_Flag on ZX_LINES.

318: IF (p_event_class_rec.tax_event_type_code = 'RE-DISTRIBUTE')
319: AND p_event_class_rec.quote_flag <> 'Y'
320: THEN
321:
322: -- call TRL service to update Item_Dist_Changed_Flag on ZX_LINES.
323: --
324: ZX_TRL_MANAGE_TAX_PKG.Update_Item_Dist_Changed_Flag(
325: x_return_status,
326: p_event_class_rec);

Line 1056: FROM zx_lines

1052: SELECT tax_line_id,
1053: tax_amt,
1054: tax_amt_tax_curr,
1055: tax_amt_funcl_curr
1056: FROM zx_lines
1057: WHERE trx_id =
1058: p_event_class_rec.trx_id
1059: AND application_id =
1060: p_event_class_rec.application_id

Line 1519: from ZX_LINES

1515:
1516: CURSOR get_hold_status_csr IS
1517: select
1518: distinct tax_hold_code - tax_hold_released_code
1519: from ZX_LINES
1520: where tax_hold_code > 0
1521: and trx_id = p_transaction_rec.trx_id
1522: and application_id = p_transaction_rec.application_id
1523: and entity_code = p_transaction_rec.entity_code

Line 1832: ZX_LINES line ,

1828: THEN 'N'
1829: ELSE 'Y' END JUR_CODE_NOT_EFFECTIVE
1830:
1831: FROM
1832: ZX_LINES line ,
1833: ZX_REGIMES_B regime ,
1834: ZX_TAXES_B tax ,
1835: ZX_STATUS_B status ,
1836: ZX_RATES_B rate ,

Line 1963: FROM zx_rec_nrec_dist zd, zx_reverse_dist_gt gt, zx_lines zl

1959: l_summary_tax_line_id_tbl,
1960: l_rvrsng_trx_number_tbl,
1961: l_org_id_tbl,
1962: l_gl_date_tbl
1963: FROM zx_rec_nrec_dist zd, zx_reverse_dist_gt gt, zx_lines zl
1964: WHERE zd.application_id = gt.reversed_appln_id
1965: AND zd.entity_code = gt.reversed_entity_code
1966: AND zd.event_class_code = gt.reversed_evnt_cls_code
1967: AND zd.trx_id = gt.reversed_trx_id

Line 3239: from zx_lines

3235: and p_gl_date between nvl(start_date_active,p_gl_date) and nvl(end_date_active, p_gl_date);
3236:
3237: Cursor line_acc_src_tax_rate_id(p_tax_line_id IN NUMBER) is
3238: select account_source_tax_rate_id
3239: from zx_lines
3240: where tax_line_id = p_tax_line_id;
3241:
3242: Cursor get_location_segment_id_csr(p_tax_line_id IN NUMBER) is
3243: select location_segment_id

Line 3244: from ra_customer_trx_lines_all inv, zx_lines cm, zx_lines zxinv

3240: where tax_line_id = p_tax_line_id;
3241:
3242: Cursor get_location_segment_id_csr(p_tax_line_id IN NUMBER) is
3243: select location_segment_id
3244: from ra_customer_trx_lines_all inv, zx_lines cm, zx_lines zxinv
3245: where cm.tax_line_id = p_tax_line_id
3246: and cm.adjusted_doc_trx_id = inv.customer_trx_id
3247: and cm.adjusted_doc_tax_line_id = inv.tax_line_id
3248: and inv.line_type = 'TAX'

Line 3554: p_tax_line_rec IN zx_lines%ROWTYPE,

3550: | |
3551: * ======================================================================*/
3552:
3553: PROCEDURE insert_item_dist(
3554: p_tax_line_rec IN zx_lines%ROWTYPE,
3555: x_return_status OUT NOCOPY VARCHAR2) IS
3556:
3557: BEGIN
3558:

Line 3665: FROM zx_lines_det_factors

3661: --p_tax_line_rec.doc_event_status,
3662: p_tax_line_rec.tax_amt,
3663: -- 'N', -- Quote_Flag what should it be?
3664: Historical_Flag
3665: FROM zx_lines_det_factors
3666: WHERE application_id = p_tax_line_rec.application_id
3667: AND event_class_code = p_tax_line_rec.event_class_code
3668: AND entity_code = p_tax_line_rec.entity_code
3669: AND trx_id = p_tax_line_rec.trx_id

Line 3725: SELECT * FROM zx_lines

3721:
3722: detail_ctr number;
3723:
3724: CURSOR fetch_tax_lines_csr IS
3725: SELECT * FROM zx_lines
3726: WHERE trx_id = p_event_class_rec.trx_id
3727: AND application_id = p_event_class_rec.application_id
3728: AND entity_code = p_event_class_rec.entity_code
3729: AND event_class_code = p_event_class_rec.event_class_code

Line 4005: FROM zx_lines_det_factors

4001: bill_third_pty_acct_id,
4002: document_sub_type,
4003: -- End : Added columns for Bug#7008557
4004: tax_reporting_flag
4005: FROM zx_lines_det_factors
4006: WHERE application_id = p_tax_line_tbl(p_index).application_id
4007: AND entity_code = p_tax_line_tbl(p_index).entity_code
4008: AND event_class_code = p_tax_line_tbl(p_index).event_class_code
4009: AND trx_id = p_tax_line_tbl(p_index).trx_id

Line 4102: 'NO DATA found in zx_lines_det_factors for trx line'||

4098: IF get_trx_info_csr%NOTFOUND THEN
4099: IF (g_level_statement >= g_current_runtime_level ) THEN
4100: FND_LOG.STRING(g_level_statement,
4101: 'ZX.PLSQL.ZX_TRD_SERVICES_PUB_PKG.populate_trx_line_info',
4102: 'NO DATA found in zx_lines_det_factors for trx line'||
4103: p_tax_line_tbl(p_index).trx_line_id);
4104: END IF;
4105: END IF;
4106: CLOSE get_trx_info_csr;

Line 4419: FROM zx_lines

4415: ORDER BY tax_line_id, unrounded_rec_nrec_tax_amt DESC;
4416:
4417: CURSOR get_tax_line_amt_csr(p_tax_line_id NUMBER) IS
4418: SELECT tax_amt_funcl_curr
4419: FROM zx_lines
4420: WHERE tax_line_id = p_tax_line_id;
4421:
4422: CURSOR get_mau_info_csr IS
4423: SELECT nvl( cur.minimum_accountable_unit, power( 10, (-1 * precision))),

Line 4706: -- 6. Get tax amount from zx_lines for this tax_line_id

4702: -- 3. Calculate rounding difference for recoverable tax.
4703: -- 4. Calculate rounding difference for non-recoverable tax.
4704: -- 5. If rounding difference exists, adjust it to recoverable or
4705: -- non-recoverable tax distribution repeecttively.
4706: -- 6. Get tax amount from zx_lines for this tax_line_id
4707: -- 7. Calculate rounding difference for all tax distributions with
4708: -- the same tax_line_id.
4709: -- 8. If rounding difference > 0, adjust it to the largest
4710: -- non_recoverable tax distribution. If rounding difference < 0,

Line 4992: -- check rounding difference between tax line in zx_lines and

4988: END IF; -- l_non_zero_nrec(or rec)_tax_lines_tbl.COUNT <> 0
4989:
4990: END IF; -- l_nrec_tax_rounding_diff <> 0
4991:
4992: -- check rounding difference between tax line in zx_lines and
4993: -- the tax distributions in zx_rec_nrec_tax_dist with the same
4994: -- tax_line_id.
4995: --
4996: -- get the tax_amt for this tax_line_id in zx_lines

Line 4996: -- get the tax_amt for this tax_line_id in zx_lines

4992: -- check rounding difference between tax line in zx_lines and
4993: -- the tax distributions in zx_rec_nrec_tax_dist with the same
4994: -- tax_line_id.
4995: --
4996: -- get the tax_amt for this tax_line_id in zx_lines
4997: --
4998: OPEN get_tax_line_amt_csr(l_tax_line_id_tbl(i));
4999: FETCH get_tax_line_amt_csr INTO l_total_tax_line_amt;
5000: CLOSE get_tax_line_amt_csr;

Line 5113: -- line in zx_lines and rec_nrec_tax_amt_funcl_curr of the tax

5109: THEN
5110:
5111: -- If a tax line has only one tax distribution, there should not
5112: -- be rounding difference between the tax_amt_funcl_curr of the tax
5113: -- line in zx_lines and rec_nrec_tax_amt_funcl_curr of the tax
5114: -- distributions in zx_rec_nrec_tax_dist with the same tax_line_id.
5115: -- They are all converted from the same unrounded_tax_amt.
5116: -- So, no action is required here.
5117:

Line 5127: -- zx_lines has multiple tax distributions in rec_nrec_tax_dist.

5123: --
5124:
5125:
5126: -- Initialize the PLSQL tables and local variables if a tax line in
5127: -- zx_lines has multiple tax distributions in rec_nrec_tax_dist.
5128: --
5129: l_non_zero_rec_tax_lines_tbl.DELETE;
5130: l_non_zero_nrec_tax_lines_tbl.DELETE;
5131:

Line 5503: c_tax_line_id zx_lines.tax_line_id%TYPE) IS

5499: c_tax zx_taxes_b.tax%TYPE,
5500: c_tax_regime_code zx_regimes_b.tax_regime_code%TYPE,
5501: c_recovery_type_code zx_rules_b.recovery_type_code%TYPE,
5502: -- c_reference_application_id zx_rules_b.application_id%TYPE,
5503: c_tax_line_id zx_lines.tax_line_id%TYPE) IS
5504: SELECT rules.service_type_code,
5505: rules.priority,
5506: factor_dtls.determining_factor_code
5507: FROM zx_sco_rules_b_v rules,

Line 5508: zx_lines lines,

5504: SELECT rules.service_type_code,
5505: rules.priority,
5506: factor_dtls.determining_factor_code
5507: FROM zx_sco_rules_b_v rules,
5508: zx_lines lines,
5509: zx_evnt_cls_mappings mappings,
5510: zx_det_factor_templ_b factors,
5511: zx_det_factor_templ_dtl factor_dtls
5512: WHERE rules.service_type_code = c_service_type_code

Line 5723: FROM ZX_LINES

5719: BEGIN
5720:
5721: SELECT INTERNAL_ORGANIZATION_ID
5722: INTO l_internal_org_id
5723: FROM ZX_LINES
5724: WHERE tax_line_id = p_tax_line_id;
5725:
5726: EXCEPTION
5727: WHEN OTHERS THEN

Line 6120: from zx_lines

6116: l_error_buffer VARCHAR2(200);
6117:
6118: Cursor line_acc_src_tax_rate_id(p_tax_line_id IN NUMBER) is
6119: select account_source_tax_rate_id
6120: from zx_lines
6121: where tax_line_id = p_tax_line_id;
6122:
6123: Cursor get_location_id(c_tax_line_id number) is
6124: SELECT det.ship_to_location_id,det.ship_from_location_id,

Line 6126: FROM zx_lines_det_factors det, zx_lines

6122:
6123: Cursor get_location_id(c_tax_line_id number) is
6124: SELECT det.ship_to_location_id,det.ship_from_location_id,
6125: det.bill_to_location_id,det.bill_from_location_id,det.trx_date
6126: FROM zx_lines_det_factors det, zx_lines
6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code

Line 6127: WHERE det.trx_id = zx_lines.trx_id

6123: Cursor get_location_id(c_tax_line_id number) is
6124: SELECT det.ship_to_location_id,det.ship_from_location_id,
6125: det.bill_to_location_id,det.bill_from_location_id,det.trx_date
6126: FROM zx_lines_det_factors det, zx_lines
6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code

Line 6128: and det.trx_line_id = zx_lines.trx_line_id

6124: SELECT det.ship_to_location_id,det.ship_from_location_id,
6125: det.bill_to_location_id,det.bill_from_location_id,det.trx_date
6126: FROM zx_lines_det_factors det, zx_lines
6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code
6132: and zx_lines.tax_line_id = c_tax_line_id;

Line 6129: and det.application_id = zx_lines.application_id

6125: det.bill_to_location_id,det.bill_from_location_id,det.trx_date
6126: FROM zx_lines_det_factors det, zx_lines
6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code
6132: and zx_lines.tax_line_id = c_tax_line_id;
6133:

Line 6130: and det.entity_code = zx_lines.entity_code

6126: FROM zx_lines_det_factors det, zx_lines
6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code
6132: and zx_lines.tax_line_id = c_tax_line_id;
6133:
6134: Cursor get_geography_type(c_tax_rate_id number) is

Line 6131: and det.event_class_code = zx_lines.event_class_code

6127: WHERE det.trx_id = zx_lines.trx_id
6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code
6132: and zx_lines.tax_line_id = c_tax_line_id;
6133:
6134: Cursor get_geography_type(c_tax_rate_id number) is
6135: SELECT zone_geography_type,tax,tax_regime_code

Line 6132: and zx_lines.tax_line_id = c_tax_line_id;

6128: and det.trx_line_id = zx_lines.trx_line_id
6129: and det.application_id = zx_lines.application_id
6130: and det.entity_code = zx_lines.entity_code
6131: and det.event_class_code = zx_lines.event_class_code
6132: and zx_lines.tax_line_id = c_tax_line_id;
6133:
6134: Cursor get_geography_type(c_tax_rate_id number) is
6135: SELECT zone_geography_type,tax,tax_regime_code
6136: FROM ZX_SCO_TAXES_B_V

Line 6143: FROM zx_lines

6139: WHERE tax_rate_id = c_tax_rate_id);
6140:
6141: Cursor is_jurisdiction_acc_appl(c_tax_line_id number) is
6142: SELECT Count(*)
6143: FROM zx_lines
6144: WHERE tax_line_id = c_tax_line_id
6145: AND tax_provider_id IS NOT NULL;
6146:
6147: l_content_owner_id NUMBER;