DBA Data[Home] [Help]

APPS.PNT_LOCATIONS_PKG dependencies on PN_LOCATIONS_ALL

Line 25: FROM pn_locations_all

21:
22: CURSOR For_Insert_Cur (p_loc_cd VARCHAR2, p_loc_type_cd VARCHAR2, p_org_id NUMBER)
23: IS
24: SELECT MIN(active_start_date), MAX(active_end_date)
25: FROM pn_locations_all
26: WHERE location_code = p_loc_cd
27: AND location_type_lookup_code = p_loc_type_cd
28: AND org_id = p_org_id;
29:

Line 33: FROM pn_locations_all

29:
30: CURSOR For_Update_St_Cur (p_loc_id NUMBER, p_str_dt DATE, p_str_dt_old DATE)
31: IS
32: SELECT TO_NUMBER(MIN(p_str_dt - active_end_date)) start_date_diff
33: FROM pn_locations_all
34: WHERE location_id = p_loc_id
35: AND ROWID <> g_pn_locations_rowid
36: AND active_end_date < p_str_dt_old;
37:

Line 41: FROM pn_locations_all

37:
38: CURSOR For_Update_End_Cur (p_loc_id NUMBER, p_end_dt DATE, p_end_dt_old DATE)
39: IS
40: SELECT TO_NUMBER(MAX(p_end_dt - active_start_date)) end_date_diff
41: FROM pn_locations_all
42: WHERE location_id = p_loc_id
43: AND ROWID <> g_pn_locations_rowid
44: AND active_start_date > p_end_dt_old;
45:

Line 76: FROM pn_locations_all

72: p_lkp_code IN VARCHAR2,
73: p_act_str_dt IN DATE,
74: p_act_end_dt IN DATE) IS
75: SELECT location_id, active_start_date, active_end_date, NVL(rentable_area,0) rentable_area
76: FROM pn_locations_all
77: WHERE location_type_lookup_code = p_lkp_code
78: AND active_start_date <= NVL(p_act_end_dt, TO_DATE('12/31/4712','MM/DD/YYYY'))
79: AND active_end_date >= p_act_str_dt
80: START WITH location_id = p_loc_id

Line 364: FROM pn_locations_all

360: -- Location ID, Active Start Date, Active End Date are the old values retrived by the query
361:
362: SELECT ROWID
363: INTO l_rowid
364: FROM pn_locations_all
365: WHERE location_id = p_location_id
366: AND active_start_date = p_active_start_date
367: AND active_end_date = NVL(p_active_end_date,g_end_of_time);
368:

Line 414: FROM pn_locations_all

410: l_cascade_cust VARCHAR2(30) := SUBSTR(p_cascade, 4, 1);
411:
412: CURSOR parent_location_cursor IS
413: SELECT *
414: FROM pn_locations_all
415: WHERE location_id = g_loc_recinfo_tmp.parent_location_id
416: AND active_start_date <= g_loc_recinfo_tmp.active_end_date
417: AND active_end_date >= g_loc_recinfo_tmp.active_start_date;
418:

Line 519: p_pn_locations_rec IN pn_locations_all%ROWTYPE

515: -- 21-JAN-2008 acprakas o Bug#6755579: Commented code which sets g_loc_recinfo_tmp.common_area_flag
516: -- to NULL.
517: -------------------------------------------------------------------------------
518: PROCEDURE Correct_Update_Row(
519: p_pn_locations_rec IN pn_locations_all%ROWTYPE
520: ,p_pn_addresses_rec IN pn_addresses_all%ROWTYPE
521: ,p_change_mode IN VARCHAR2
522: ,p_as_of_date IN DATE
523: ,p_active_start_date_old IN DATE

Line 544: FROM pn_locations_all

540: l_as_of_date DATE := NULL;
541:
542: CURSOR location_cursor_old is
543: SELECT *
544: FROM pn_locations_all
545: WHERE location_id = p_pn_locations_rec.location_id
546: AND active_start_date = NVL(p_active_start_date_old, g_start_of_time)
547: AND active_end_date = NVL(p_active_end_date_old, g_end_of_time);
548:

Line 857: FROM pn_locations_all

853: l_cascade_cust VARCHAR2(30) := SUBSTR(p_cascade, 4, 1);
854:
855: CURSOR location_cursor IS
856: SELECT *
857: FROM pn_locations_all
858: START WITH ( parent_location_id = p_location_id
859: AND active_start_date <= NVL(p_end_date, TO_DATE('12/31/4712','MM/DD/YYYY'))
860: AND active_end_date >= p_start_date
861: )

Line 1032: FROM pn_locations_all

1028: SELECT 'TRUE'
1029: FROM DUAL
1030: WHERE EXISTS (SELECT NULL
1031: FROM pn_space_assign_cust_all, (SELECT location_id loc_id
1032: FROM pn_locations_all
1033: WHERE active_start_date <= l_end_date
1034: AND active_end_date >= l_str_date
1035: START WITH location_id = p_location_id
1036: CONNECT BY PRIOR location_id = parent_location_id

Line 1050: FROM pn_locations_all

1046: AND cust_assign_start_date <= l_end_date
1047: AND NVL(cust_assign_end_date, TO_DATE('12/31/4712','MM/DD/YYYY')) >= l_str_date)
1048: OR EXISTS (SELECT NULL
1049: FROM pn_space_assign_emp_all, (SELECT location_id loc_id
1050: FROM pn_locations_all
1051: WHERE active_start_date <= l_end_date
1052: AND active_end_date >= l_str_date
1053: START WITH location_id = p_location_id
1054: CONNECT BY PRIOR location_id = parent_location_id

Line 1118: FROM pn_locations_all

1114: CURSOR check_loc_status_csr IS
1115: SELECT 'TRUE'
1116: FROM DUAL
1117: WHERE EXISTS (SELECT NULL
1118: FROM pn_locations_all
1119: WHERE location_id = p_parent_location_id
1120: AND active_start_date <= l_end_date
1121: AND active_end_date >= l_str_date
1122: AND ((p_status_mode IN ('OCC') AND NVL(occupancy_status_code, 'Y') = 'N')

Line 1169: -- from pn_locations_all instead of pn_locations

1165: -- Added parameters occupancy_status_code,
1166: -- assignable_emp, assignable_cc, assignable_cust,
1167: -- disposition, acc_treatment.
1168: -- 28-APR-05 piagrawa o Modified the select statements to retrieve values
1169: -- from pn_locations_all instead of pn_locations
1170: -- Also passed org_id as parameter to
1171: -- PNT_ADDR_PKG.insert_row
1172: -- 19-JUL-05 SatyaDeep o Added argument x_source to insert the source
1173: -- product from pn_locations_itf for bug#4468893

Line 1287: FROM pn_locations_all

1283: IS
1284:
1285: CURSOR c IS
1286: SELECT ROWID
1287: FROM pn_locations_all
1288: WHERE location_id = x_location_id
1289: AND active_start_date = NVL(x_active_start_date, g_start_of_time)
1290: AND active_end_date = NVL(x_active_end_date, g_end_of_time);
1291:

Line 1475: INSERT INTO pn_locations_all (

1471: END IF;
1472:
1473: pnp_debug_pkg.debug(' InsRow> before insert' || x_change_mode);
1474: BEGIN
1475: INSERT INTO pn_locations_all (
1476: LOCATION_ID
1477: ,LAST_UPDATE_DATE
1478: ,LAST_UPDATED_BY
1479: ,CREATION_DATE

Line 1785: UPDATE PN_LOCATIONS_ALL

1781: END IF;
1782:
1783: pnp_debug_pkg.put_log_msg('update locations');
1784:
1785: UPDATE PN_LOCATIONS_ALL
1786: SET
1787: LAST_UPDATE_DATE = x_LAST_UPDATE_DATE
1788: ,LAST_UPDATED_BY = x_LAST_UPDATED_BY
1789: ,LAST_UPDATE_LOGIN = x_LAST_UPDATE_LOGIN

Line 2020: FROM pn_locations_all

2016:
2017:
2018: CURSOR c IS
2019: SELECT *
2020: FROM pn_locations_all
2021: WHERE location_id = x_location_id
2022: AND active_start_date = NVL(x_active_start_date_old, g_start_of_time)
2023: AND active_end_date = NVL(x_active_end_date_old, g_end_of_time)
2024: FOR UPDATE OF location_id NOWAIT;

Line 2438: FROM pn_locations_all

2434: CURSOR check_tenancy IS
2435: SELECT 'Y'
2436: FROM pn_tenancies_all pt
2437: WHERE location_id IN (SELECT location_id
2438: FROM pn_locations_all
2439: WHERE active_start_date > p_active_end_date
2440: START WITH location_id = p_location_id
2441: CONNECT BY PRIOR location_id = parent_location_id)
2442: AND NOT EXISTS (SELECT '1'

Line 2443: FROM pn_locations_all pl1

2439: WHERE active_start_date > p_active_end_date
2440: START WITH location_id = p_location_id
2441: CONNECT BY PRIOR location_id = parent_location_id)
2442: AND NOT EXISTS (SELECT '1'
2443: FROM pn_locations_all pl1
2444: where pl1.location_id = pt.location_id
2445: AND active_start_date <= p_active_end_date)
2446: AND ROWNUM < 2;
2447:

Line 2452: FROM pn_locations_all

2448: CURSOR check_start_tenancy IS
2449: SELECT 'Y'
2450: FROM pn_tenancies_all pt
2451: WHERE location_id IN (SELECT location_id
2452: FROM pn_locations_all
2453: WHERE active_end_date < p_active_start_date
2454: START WITH location_id = p_location_id
2455: CONNECT BY PRIOR location_id = parent_location_id)
2456: AND NOT EXISTS (SELECT '1'

Line 2457: FROM pn_locations_all pl1

2453: WHERE active_end_date < p_active_start_date
2454: START WITH location_id = p_location_id
2455: CONNECT BY PRIOR location_id = parent_location_id)
2456: AND NOT EXISTS (SELECT '1'
2457: FROM pn_locations_all pl1
2458: WHERE pl1.location_id = pt.location_id
2459: AND active_end_date >= p_active_start_date)
2460: AND ROWNUM < 2;
2461:

Line 2488: DELETE FROM pn_locations_all

2484: x_return_status := 'E';
2485: RETURN;
2486: END IF;
2487:
2488: DELETE FROM pn_locations_all
2489: WHERE (location_id, active_start_date,active_end_date) IN
2490: (SELECT location_id, active_start_date,active_end_date
2491: FROM pn_locations_all pl
2492: WHERE active_start_date > p_active_end_date

Line 2491: FROM pn_locations_all pl

2487:
2488: DELETE FROM pn_locations_all
2489: WHERE (location_id, active_start_date,active_end_date) IN
2490: (SELECT location_id, active_start_date,active_end_date
2491: FROM pn_locations_all pl
2492: WHERE active_start_date > p_active_end_date
2493: AND NOT EXISTS (SELECT '1'
2494: FROM pn_space_assign_emp_all
2495: WHERE location_id = pl.location_id

Line 2507: UPDATE pn_locations_all

2503: START WITH location_id = p_location_id
2504: CONNECT BY PRIOR location_id = parent_location_id);
2505:
2506:
2507: UPDATE pn_locations_all
2508: SET active_end_date = p_active_end_date
2509: WHERE active_start_date <= p_active_end_date
2510: AND active_end_date > p_active_end_date
2511: AND location_id IN (SELECT location_id

Line 2512: FROM pn_locations_all

2508: SET active_end_date = p_active_end_date
2509: WHERE active_start_date <= p_active_end_date
2510: AND active_end_date > p_active_end_date
2511: AND location_id IN (SELECT location_id
2512: FROM pn_locations_all
2513: START WITH location_id = p_location_id
2514: CONNECT BY PRIOR location_id = parent_location_id);
2515:
2516: END IF;

Line 2533: DELETE FROM pn_locations_all

2529: x_return_status := 'E';
2530: RETURN;
2531: END IF;
2532:
2533: DELETE FROM pn_locations_all
2534: WHERE (location_id, active_start_date,active_end_date) IN
2535: (SELECT location_id, active_start_date,active_end_date
2536: FROM pn_locations_all pl
2537: WHERE active_end_date < p_active_start_date

Line 2536: FROM pn_locations_all pl

2532:
2533: DELETE FROM pn_locations_all
2534: WHERE (location_id, active_start_date,active_end_date) IN
2535: (SELECT location_id, active_start_date,active_end_date
2536: FROM pn_locations_all pl
2537: WHERE active_end_date < p_active_start_date
2538: AND NOT EXISTS (SELECT '1'
2539: FROM pn_space_assign_emp_all
2540: WHERE location_id = pl.location_id

Line 2551: UPDATE pn_locations_all

2547: AND cust_assign_end_date)
2548: START WITH location_id = p_location_id
2549: CONNECT BY PRIOR location_id = parent_location_id);
2550:
2551: UPDATE pn_locations_all
2552: SET active_start_date = p_active_start_date
2553: WHERE active_start_date < p_active_start_date
2554: AND active_end_date >= p_active_start_date
2555: AND location_id IN (SELECT location_id

Line 2556: FROM pn_locations_all

2552: SET active_start_date = p_active_start_date
2553: WHERE active_start_date < p_active_start_date
2554: AND active_end_date >= p_active_start_date
2555: AND location_id IN (SELECT location_id
2556: FROM pn_locations_all
2557: START WITH location_id = p_location_id
2558: CONNECT BY PRIOR location_id = parent_location_id);
2559:
2560: END IF;

Line 2582: PROCEDURE check_for_popup (p_pn_locations_rec pn_locations_all%rowtype,

2578: -- 01-DEC-2004 Satish Tripathi o Modified for Portfolio Status Enh BUG# 4030816.
2579: -- Added code to condider columns occupancy_status_code, assignable_emp,
2580: -- assignable_cc, assignable_cust.
2581: -------------------------------------------------------------------------------
2582: PROCEDURE check_for_popup (p_pn_locations_rec pn_locations_all%rowtype,
2583: p_start_date_old IN DATE,
2584: p_end_date_old IN DATE,
2585: x_flag OUT NOCOPY VARCHAR2,
2586: x_return_status OUT NOCOPY VARCHAR2,

Line 2951: UPDATE pn_locations_all

2947: PROCEDURE Update_Status (p_Location_Id Number) IS
2948:
2949: BEGIN
2950:
2951: UPDATE pn_locations_all
2952: SET Status = 'I'
2953: WHERE Location_Id IN (SELECT Location_Id
2954: FROM pn_locations_all
2955: START WITH Location_Id = p_Location_Id

Line 2954: FROM pn_locations_all

2950:
2951: UPDATE pn_locations_all
2952: SET Status = 'I'
2953: WHERE Location_Id IN (SELECT Location_Id
2954: FROM pn_locations_all
2955: START WITH Location_Id = p_Location_Id
2956: CONNECT BY PRIOR Location_Id = Parent_Location_id);
2957:
2958: End Update_Status ;

Line 2976: FROM pn_locations_all

2972: IS
2973:
2974: CURSOR location_cursor IS
2975: SELECT *
2976: FROM pn_locations_all
2977: START WITH location_id = p_location_id
2978: CONNECT BY PRIOR location_id = parent_location_id;
2979:
2980: BEGIN

Line 3100: FROM pn_locations_all

3096:
3097: CURSOR get_min_gross_area IS
3098: SELECT MIN(gross_area) min_gross_area,
3099: location_id location_id
3100: FROM pn_locations_all
3101: WHERE parent_location_id IS NULL
3102: AND active_start_date <= l_act_end_dt
3103: AND active_end_date >= p_act_str_dt
3104: START WITH location_id = p_loc_id

Line 3110: FROM pn_locations_all

3106: GROUP BY location_id;
3107:
3108: CURSOR get_old_rent_area IS
3109: SELECT rentable_area
3110: FROM pn_locations_all
3111: WHERE location_id = p_loc_id
3112: AND location_type_lookup_code = p_lkp_code
3113: AND active_start_date <= NVL(p_act_end_dt, TO_DATE('12/31/4712','MM/DD/YYYY'))
3114: AND active_end_date >= p_act_str_dt;

Line 3227: FROM pn_locations_all

3223: CURSOR get_loctn_dates IS
3224: SELECT location_id,
3225: active_start_date,
3226: active_end_date
3227: FROM pn_locations_all
3228: WHERE active_end_date >= p_str_dt
3229: AND active_start_date <= p_end_dt
3230: AND location_id = p_loc_id
3231: AND ((p_asgn_mode = 'NONE') OR

Line 3242: FROM pn_locations_all

3238: CURSOR check_loctn_gap(l_date IN DATE) IS
3239: SELECT 'Y'
3240: FROM DUAL
3241: WHERE NOT EXISTS (SELECT NULL
3242: FROM pn_locations_all
3243: WHERE l_date BETWEEN active_start_date AND active_end_date
3244: AND location_id = p_loc_id
3245: AND ((p_asgn_mode = 'NONE') OR
3246: (p_asgn_mode = 'EMP' AND NVL(assignable_emp, 'Y') = 'Y' AND NVL(assignable_cc, 'Y') = 'Y') OR

Line 3337: FROM pn_locations_all

3333:
3334: CURSOR get_loctn_span IS
3335: SELECT MIN(active_start_date)
3336: ,MAX(active_end_date)
3337: FROM pn_locations_all
3338: WHERE location_id = p_loc_id
3339: AND ((p_asgn_mode = 'NONE') OR
3340: (p_asgn_mode = 'EMP' AND NVL(assignable_emp, 'Y') = 'Y' AND NVL(assignable_cc, 'Y') = 'Y') OR
3341: (p_asgn_mode = 'CC' AND NVL(assignable_cc, 'Y') = 'Y') OR

Line 3361: -- pn_locations_all%ROWTYPE passed to it. Called from

3357:
3358: -----------------------------------------------------------------------
3359: -- PROCEDURE : Update_Locn_Row
3360: -- PURPOSE : This procedure calls pnt_locations_pkg.Update_Row for the
3361: -- pn_locations_all%ROWTYPE passed to it. Called from
3362: -- Correct_Update_Row and Cascade_Child_Locn
3363: -- IN PARAM :
3364: -- History :
3365: -- 01-DEC-2004 Satish Tripathi o Created for Portfolio Status Enh BUG# 4030816.

Line 3370: p_loc_recinfo IN pn_locations_all%ROWTYPE

3366: -- 02-AUG-2005 Satya Deep o Added X_SOURCE in the call to
3367: -- pnt_locations_pkg.Update_Row
3368: -----------------------------------------------------------------------
3369: PROCEDURE Update_Locn_Row (
3370: p_loc_recinfo IN pn_locations_all%ROWTYPE
3371: ,p_adr_recinfo IN pn_addresses_all%ROWTYPE
3372: ,p_assgn_area_chgd_flag IN VARCHAR2
3373: ,x_return_status IN OUT NOCOPY VARCHAR2
3374: ,x_return_message IN OUT NOCOPY VARCHAR2

Line 3378: l_location_id pn_locations_all.location_id%TYPE;

3374: ,x_return_message IN OUT NOCOPY VARCHAR2
3375: )
3376: IS
3377: l_rowid ROWID;
3378: l_location_id pn_locations_all.location_id%TYPE;
3379: l_address_id pn_locations_all.address_id%TYPE;
3380: BEGIN
3381:
3382: pnp_debug_pkg.debug('PNT_LOCATIONS_PKG.Update_Locn_Row (+) LocId: '||p_loc_recinfo.location_id

Line 3379: l_address_id pn_locations_all.address_id%TYPE;

3375: )
3376: IS
3377: l_rowid ROWID;
3378: l_location_id pn_locations_all.location_id%TYPE;
3379: l_address_id pn_locations_all.address_id%TYPE;
3380: BEGIN
3381:
3382: pnp_debug_pkg.debug('PNT_LOCATIONS_PKG.Update_Locn_Row (+) LocId: '||p_loc_recinfo.location_id
3383: ||', LocCd: '||p_loc_recinfo.location_code

Line 3504: -- pn_locations_all%ROWTYPE passed to it. Called from

3500:
3501: -----------------------------------------------------------------------
3502: -- PROCEDURE : Insert_Locn_Row
3503: -- PURPOSE : This procedure calls pnt_locations_pkg.Insert_Row for the
3504: -- pn_locations_all%ROWTYPE passed to it. Called from
3505: -- Correct_Update_Row and Cascade_Child_Locn
3506: -- IN PARAM :
3507: -- History :
3508: -- 01-DEC-2004 Satish Tripathi o Created for Portfolio Status Enh BUG# 4030816.

Line 3513: p_loc_recinfo IN pn_locations_all%ROWTYPE

3509: -- 02-AUG-2005 Satya Deep o Added X_SOURCE in the call to
3510: -- pnt_locations_pkg.Insert_Row
3511: -----------------------------------------------------------------------
3512: PROCEDURE Insert_Locn_Row (
3513: p_loc_recinfo IN pn_locations_all%ROWTYPE
3514: ,p_adr_recinfo IN pn_addresses_all%ROWTYPE
3515: ,p_change_mode IN VARCHAR2
3516: ,x_return_status IN OUT NOCOPY VARCHAR2
3517: ,x_return_message IN OUT NOCOPY VARCHAR2

Line 3521: l_location_id pn_locations_all.location_id%TYPE;

3517: ,x_return_message IN OUT NOCOPY VARCHAR2
3518: )
3519: IS
3520: l_rowid ROWID;
3521: l_location_id pn_locations_all.location_id%TYPE;
3522: l_address_id pn_locations_all.address_id%TYPE;
3523: BEGIN
3524: pnp_debug_pkg.debug('PNT_LOCATIONS_PKG.Insert_Locn_Row (+) LocId: '||p_loc_recinfo.location_id
3525: ||', LocCd: '||p_loc_recinfo.location_code

Line 3522: l_address_id pn_locations_all.address_id%TYPE;

3518: )
3519: IS
3520: l_rowid ROWID;
3521: l_location_id pn_locations_all.location_id%TYPE;
3522: l_address_id pn_locations_all.address_id%TYPE;
3523: BEGIN
3524: pnp_debug_pkg.debug('PNT_LOCATIONS_PKG.Insert_Locn_Row (+) LocId: '||p_loc_recinfo.location_id
3525: ||', LocCd: '||p_loc_recinfo.location_code
3526: ||', Type: '||p_loc_recinfo.location_type_lookup_code);

Line 3674: FROM pn_locations_all

3670:
3671:
3672: SELECT location_id
3673: INTO l_location_id
3674: FROM pn_locations_all
3675: WHERE location_code = p_location_code
3676: AND location_type_lookup_code = p_loctn_type_lookup_code
3677: AND org_id = p_org_id
3678: AND ROWNUM = 1;

Line 3717: FROM pn_locations_all pnl

3713: CURSOR loc_code_cur IS
3714: SELECT 1
3715: FROM DUAL
3716: WHERE EXISTS (SELECT 1
3717: FROM pn_locations_all pnl
3718: WHERE pnl.location_code = x_location_code
3719: AND pnl.active_start_date = x_active_start_date
3720: AND pnl.active_end_date = NVL(x_active_end_date,g_end_of_time)
3721: AND ((x_location_id IS NULL) OR (pnl.location_id <> x_location_id))

Line 3768: FROM pn_locations_all pnl

3764: CURSOR building_cur IS
3765: SELECT 1
3766: FROM DUAL
3767: WHERE EXISTS (SELECT 1
3768: FROM pn_locations_all pnl
3769: WHERE UPPER(pnl.building) = UPPER(x_building)
3770: AND ((x_location_id IS NULL) OR (pnl.location_id <> x_location_id))
3771: AND pnl.active_start_date <= x_active_start_date
3772: AND pnl.active_end_date >= x_active_end_date

Line 3817: FROM pn_locations_all loc

3813: l_token VARCHAR2(30);
3814:
3815: CURSOR dupAlias IS
3816: SELECT loc.location_id AS location_id
3817: FROM pn_locations_all loc
3818: WHERE loc.LOCATION_TYPE_LOOKUP_CODE = p_location_type_lookup_code
3819: AND loc.location_alias = p_location_alias
3820: AND loc.location_id <> NVL(p_location_id,-1)
3821: AND loc.org_id = p_org_id;

Line 3870: FROM pn_locations_all pnl

3866: CURSOR loc_alias_cur IS
3867: SELECT 1
3868: FROM DUAL
3869: WHERE EXISTS (SELECT 1
3870: FROM pn_locations_all pnl
3871: WHERE pnl.location_alias = x_location_alias
3872: AND location_type_lookup_code = x_location_type_lookup_code
3873: AND ((x_location_id IS NULL) OR (pnl.location_id <> x_location_id))
3874: AND pnl.parent_location_id = x_parent_location_id