DBA Data[Home] [Help]

APPS.PNP_UTIL_FUNC dependencies on PN_LOCATIONS_ALL

Line 311: FROM PN_LOCATIONS_ALL

307: AND emp_assign_start_date <= p_As_Of_Date
308: AND NVL(emp_assign_end_date, l_date) >= p_As_Of_Date
309: AND Location_Id IN (
310: SELECT Location_Id
311: FROM PN_LOCATIONS_ALL
312: WHERE Location_Type_Lookup_Code = 'OFFICE'
313: AND p_As_Of_Date BETWEEN active_start_date AND active_end_date
314: START WITH Location_Id = p_Location_Id
315: CONNECT BY PRIOR Location_Id = Parent_Location_Id

Line 330: FROM PN_LOCATIONS_ALL

326: WHERE cust_assign_start_date <= p_As_Of_Date
327: AND NVL(cust_assign_end_date, l_date) >= p_As_Of_Date
328: AND Location_Id IN (
329: SELECT Location_Id
330: FROM PN_LOCATIONS_ALL
331: WHERE Location_Type_Lookup_Code = 'OFFICE'
332: AND p_As_Of_Date BETWEEN active_start_date AND active_end_date
333: START WITH Location_Id = p_Location_Id
334: CONNECT BY PRIOR Location_Id = Parent_Location_Id

Line 456: FROM pn_locations_all

452: CURSOR Assignable_Area_C(p_Location_Id IN NUMBER
453: ,p_As_of_date IN DATE
454: ,p_location_type IN VARCHAR2) IS
455: (SELECT NVL(SUM(assignable_area), 0) AS Area
456: FROM pn_locations_all
457: WHERE location_type_lookup_code = p_location_type
458: AND status = 'A'
459: AND p_as_of_date BETWEEN active_start_date AND active_end_date
460: START WITH location_id = p_Location_Id

Line 473: FROM pn_locations_all

469: FROM pn_space_assign_emp_all
470: WHERE emp_assign_start_date <= p_as_of_date
471: AND NVL(emp_assign_end_date, l_date) >= p_as_of_date
472: AND location_id IN (SELECT Location_Id
473: FROM pn_locations_all
474: WHERE location_type_lookup_code = p_location_type
475: AND Status = 'A'
476: AND p_as_of_date BETWEEN active_start_date AND active_end_date
477: START WITH Location_Id = p_Location_Id

Line 488: FROM pn_locations_all

484: CURSOR c_location_id (p_Location_Id IN NUMBER
485: ,p_As_of_date IN DATE
486: ,p_location_type IN VARCHAR2) IS
487: SELECT Location_Id
488: FROM pn_locations_all
489: WHERE location_type_lookup_code = p_location_type
490: AND Status = 'A'
491: AND p_as_of_date BETWEEN active_start_date AND active_end_date
492: START WITH Location_Id = p_Location_Id

Line 514: FROM pn_locations_all

510: FROM pn_space_assign_cust_all
511: WHERE cust_assign_start_date <= p_As_of_date
512: AND NVL(cust_assign_end_date, l_date) >= p_As_of_date
513: AND location_Id IN (SELECT location_id
514: FROM pn_locations_all
515: WHERE location_type_lookup_code = p_location_type
516: AND status = 'A'
517: AND p_as_of_date BETWEEN active_start_date AND active_end_date
518: START WITH location_id = p_location_id

Line 527: FROM pn_locations_all

523:
524: CURSOR Assignable_Area_Child_C(p_Location_Id IN NUMBER
525: ,p_As_of_date IN DATE) IS
526: (SELECT NVL(SUM(assignable_area), 0) AS Area
527: FROM pn_locations_all
528: WHERE location_id = p_location_id
529: AND p_as_of_date BETWEEN active_start_date AND active_end_date
530: AND status = 'A'
531: );

Line 541: FROM pn_locations_all l

537: WHERE E.emp_assign_start_date >= p_as_of_date
538: AND NVL(e.emp_assign_end_date, l_date) >= p_as_of_date
539: AND e.location_id = p_location_id
540: AND EXISTS (SELECT NULL
541: FROM pn_locations_all l
542: WHERE l.status = 'A'
543: AND l.location_id = p_Location_Id)
544: );
545:

Line 554: FROM pn_locations_all l

550: WHERE c.cust_assign_start_date <= p_as_of_date
551: AND NVL(c.cust_assign_end_date, l_date) >= p_as_of_date
552: AND c.location_id = p_location_id
553: AND EXISTS (SELECT NULL
554: FROM pn_locations_all l
555: WHERE l.status = 'A'
556: AND l.location_id = p_location_id)
557: );
558:

Line 915: (SELECT COUNT(pn_locations_all.floor) AS floor_count

911:
912: CURSOR floor_count_C( p_Location_Id NUMBER
913: ,p_as_of_date DATE
914: ,p_location_type VARCHAR2) IS
915: (SELECT COUNT(pn_locations_all.floor) AS floor_count
916: FROM pn_locations_all
917: WHERE Location_Type_Lookup_Code = p_location_type
918: AND Status = 'A'
919: AND p_as_of_date BETWEEN active_start_date AND active_end_date

Line 916: FROM pn_locations_all

912: CURSOR floor_count_C( p_Location_Id NUMBER
913: ,p_as_of_date DATE
914: ,p_location_type VARCHAR2) IS
915: (SELECT COUNT(pn_locations_all.floor) AS floor_count
916: FROM pn_locations_all
917: WHERE Location_Type_Lookup_Code = p_location_type
918: AND Status = 'A'
919: AND p_as_of_date BETWEEN active_start_date AND active_end_date
920: START WITH Location_Id = p_Location_Id

Line 1034: FROM pn_locations_all

1030: END IF;
1031:
1032: SELECT COUNT(office)
1033: INTO l_offices
1034: FROM pn_locations_all
1035: WHERE Location_Type_Lookup_Code = l_location_type --'OFFICE'
1036: AND Status = 'A' --BUG#2168485
1037: AND l_as_of_date BETWEEN active_start_date AND active_end_date
1038: START WITH Location_Id = p_Location_Id

Line 1128: FROM pn_locations_all a

1124: p_As_Of_Date IN DATE) IS
1125: (SELECT SUM(NVL(UTILIZED_AREA,0)) AS Area
1126: FROM pn_space_assign_emp_all
1127: WHERE location_id IN (SELECT a.location_id
1128: FROM pn_locations_all a
1129: WHERE p_As_Of_Date BETWEEN active_start_date AND
1130: active_end_date
1131: START WITH a.location_id = p_location_id
1132: CONNECT BY PRIOR a.location_id = a.parent_location_id

Line 1141: FROM pn_locations_all

1137: );*/
1138: CURSOR c_location_id (p_Location_Id IN NUMBER
1139: ,p_As_of_date IN DATE) IS
1140: SELECT Location_Id
1141: FROM pn_locations_all
1142: WHERE p_as_of_date BETWEEN active_start_date AND
1143: active_end_date
1144: START WITH Location_Id = p_Location_Id
1145: CONNECT BY PRIOR Location_Id = parent_location_id

Line 1163: FROM pn_locations_all a

1159: ,p_As_Of_Date IN DATE) IS
1160: (SELECT SUM(NVL(UTILIZED_AREA,0)) AS Area
1161: FROM pn_space_assign_cust_all
1162: WHERE location_id IN (SELECT a.location_id
1163: FROM pn_locations_all a
1164: WHERE p_as_of_date BETWEEN active_start_date AND
1165: active_end_date
1166: START WITH a.location_id = p_location_id
1167: CONNECT BY PRIOR a.location_id = a.parent_location_id

Line 1579: FROM pn_locations_all pnl,

1575: p_leaseId IN NUMBER,
1576: p_as_of_date IN DATE ) IS
1577:
1578: (SELECT NVL(SUM(pnl.RENTABLE_AREA),0) AS Area
1579: FROM pn_locations_all pnl,
1580: pn_tenancies_all pnt
1581: WHERE pnt.lease_id = p_leaseId
1582: AND pnt.status = 'A'
1583: AND pnl.location_id = pnt.location_id

Line 2176: FROM pn_locations_all

2172: Begin
2173:
2174: SELECT 'X'
2175: INTO l_Dummy
2176: FROM pn_locations_all
2177: WHERE Status = 'A'
2178: AND Location_Id = p_Location_Id
2179: AND l_as_of_date BETWEEN active_start_date AND active_end_date;
2180:

Line 2465: l_location_code pn_locations_all.location_code%TYPE;

2461: p_location_id NUMBER,
2462: p_as_of_date DATE,
2463: p_ignore_date BOOLEAN) RETURN VARCHAR2
2464: IS
2465: l_location_code pn_locations_all.location_code%TYPE;
2466: l_as_of_date DATE := pnp_util_func.get_as_of_date(p_as_of_date);
2467:
2468: CURSOR fetch_loc_code IS
2469: SELECT location_code

Line 2470: FROM pn_locations_all

2466: l_as_of_date DATE := pnp_util_func.get_as_of_date(p_as_of_date);
2467:
2468: CURSOR fetch_loc_code IS
2469: SELECT location_code
2470: FROM pn_locations_all
2471: WHERE location_id = p_location_id
2472: AND p_as_of_date BETWEEN active_start_date AND active_end_date;
2473:
2474: CURSOR fetch_loc_code_ignore_date IS

Line 2476: FROM pn_locations_all

2472: AND p_as_of_date BETWEEN active_start_date AND active_end_date;
2473:
2474: CURSOR fetch_loc_code_ignore_date IS
2475: SELECT location_code
2476: FROM pn_locations_all
2477: WHERE location_id = p_location_id
2478: AND ROWNUM < 2;
2479:
2480: BEGIN

Line 2509: l_location_type_lookup_code pn_locations_all.location_type_lookup_code%TYPE;

2505: FUNCTION Get_Location_Type_Lookup_Code (p_location_id NUMBER ,
2506: p_as_of_date DATE,
2507: p_ignore_date BOOLEAN) RETURN VARCHAR2
2508: IS
2509: l_location_type_lookup_code pn_locations_all.location_type_lookup_code%TYPE;
2510: l_as_of_date DATE := pnp_util_func.get_as_of_date(p_as_of_date);
2511:
2512: CURSOR fetch_code IS
2513: SELECT location_type_lookup_code

Line 2514: FROM pn_locations_all

2510: l_as_of_date DATE := pnp_util_func.get_as_of_date(p_as_of_date);
2511:
2512: CURSOR fetch_code IS
2513: SELECT location_type_lookup_code
2514: FROM pn_locations_all
2515: WHERE location_id = p_location_id
2516: AND l_as_of_date BETWEEN active_start_date AND active_end_date;
2517:
2518: CURSOR fetch_code_ignore_date IS

Line 2520: FROM pn_locations_all

2516: AND l_as_of_date BETWEEN active_start_date AND active_end_date;
2517:
2518: CURSOR fetch_code_ignore_date IS
2519: SELECT location_type_lookup_code
2520: FROM pn_locations_all
2521: WHERE location_id = p_location_id
2522: AND ROWNUM < 2;
2523:
2524: BEGIN

Line 4470: FROM pn_locations_all

4466: CURSOR Office_Vacancy_C( p_Location_Id IN NUMBER
4467: ,p_as_of_date IN DATE
4468: ,p_location_type IN VARCHAR2) IS
4469: (SELECT NVL((max_capacity), 0) AS vacancy
4470: FROM pn_locations_all
4471: WHERE Location_Type_Lookup_Code = p_location_type
4472: AND p_as_of_date BETWEEN active_start_date AND active_end_date
4473: AND Location_Id = p_Location_Id
4474: );

Line 4558: FROM pn_locations_all

4554: FROM pn_space_assign_emp_all
4555: WHERE emp_assign_start_date > l_date
4556: --Bug#5959164 AND allocated_area_pct > 0
4557: AND location_id IN (SELECT location_id
4558: FROM pn_locations_all
4559: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4560: START WITH location_id = p_Location_Id
4561: CONNECT BY PRIOR location_id = parent_location_id
4562: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4569: FROM pn_locations_all

4565: SELECT 'Y'
4566: FROM pn_space_assign_emp_all
4567: WHERE l_date BETWEEN emp_assign_start_date AND emp_assign_end_date
4568: AND location_id IN (SELECT location_id
4569: FROM pn_locations_all
4570: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4571: START WITH location_id = p_Location_Id
4572: CONNECT BY PRIOR location_id = parent_location_id
4573: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4580: FROM pn_locations_all

4576: SELECT 'Y'
4577: FROM pn_space_assign_emp_all
4578: WHERE l_date >= emp_assign_start_date AND emp_assign_end_date IS NULL -- for open assignments time
4579: AND location_id IN (SELECT location_id
4580: FROM pn_locations_all
4581: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4582: START WITH location_id = p_Location_Id
4583: CONNECT BY PRIOR location_id = parent_location_id
4584: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4592: FROM pn_locations_all

4588: FROM pn_space_assign_cust_all
4589: WHERE cust_assign_start_date > l_date
4590: --Bug#5959164 AND allocated_area_pct > 0
4591: AND location_id IN (SELECT location_id
4592: FROM pn_locations_all
4593: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4594: START WITH location_id = p_Location_Id
4595: CONNECT BY PRIOR location_id = parent_location_id
4596: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4603: FROM pn_locations_all

4599: SELECT 'Y'
4600: FROM pn_space_assign_cust_all
4601: WHERE l_date BETWEEN cust_assign_start_date AND cust_assign_end_date
4602: AND location_id IN (SELECT location_id
4603: FROM pn_locations_all
4604: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4605: START WITH location_id = p_Location_Id
4606: CONNECT BY PRIOR location_id = parent_location_id
4607: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4614: FROM pn_locations_all

4610: SELECT 'Y'
4611: FROM pn_space_assign_cust_all
4612: WHERE l_date >= cust_assign_start_date AND cust_assign_end_date IS NULL -- for open assignments time
4613: AND location_id IN (SELECT location_id
4614: FROM pn_locations_all
4615: WHERE l_as_of_date BETWEEN active_start_date AND active_end_date
4616: START WITH location_id = p_Location_Id
4617: CONNECT BY PRIOR location_id = parent_location_id
4618: AND l_as_of_date BETWEEN PRIOR active_start_date AND PRIOR active_end_date);

Line 4789: FROM pn_locations_all

4785: ,p_location_type IN VARCHAR2) IS
4786: (SELECT NVL((USABLE_AREA), 0) AS usable_area
4787: ,NVL((ASSIGNABLE_AREA), 0) AS assignable_area
4788: ,NVL((COMMON_AREA), 0) AS common_area
4789: FROM pn_locations_all
4790: WHERE Location_Type_Lookup_Code = p_location_type
4791: AND p_as_of_date BETWEEN active_start_date AND active_end_date
4792: AND Location_Id = p_Location_Id
4793: );

Line 4898: FROM pn_locations_all

4894: end if;
4895:
4896: SELECT NVL(SUM(COMMON_AREA),0)
4897: INTO l_common_area
4898: FROM pn_locations_all
4899: WHERE Location_Type_Lookup_Code = l_location_type --'OFFICE'
4900: AND Status = 'A'
4901: AND l_as_of_date BETWEEN active_start_date AND active_end_date
4902: START WITH Location_Id = p_Location_Id

Line 4982: FROM pn_locations_all

4978: end if;
4979:
4980: SELECT NVL(SUM(COMMON_AREA),0)
4981: INTO l_common_area
4982: FROM pn_locations_all
4983: WHERE Location_Type_Lookup_Code = l_location_type
4984: AND Status = 'A'
4985: AND l_as_of_date BETWEEN active_start_date AND active_end_date
4986: START WITH Location_Id = p_Location_Id

Line 5049: FROM pn_locations_all

5045: IS
5046:
5047: CURSOR get_parent_loc_id IS
5048: SELECT parent_location_id
5049: FROM pn_locations_all
5050: WHERE location_id = p_location_id;
5051:
5052: l_parent_location_id NUMBER;
5053: BEGIN

Line 5191: -- ... for each pn_locations_all table.

5187: -- 30-OCT-02 Satish Tripathi o Access _all table for performance issues.
5188: -- 31-OCT-01 graghuna o added p_as_of_date for Location Date-Effectivity
5189: -- 20-OCT-03 ftanudja o removed nvl from locn tbl filter. 3197410.
5190: -- 02-JUL-04 Satish Tripathi o Fixed for 3740584, added l_as_of_date BETWEEN
5191: -- ... for each pn_locations_all table.
5192: -- 15-JUN-05 piagrawa o Bug 4307795 - Replaced PN_PROPERTIES
5193: -- with _ALL table.
5194: +============================================================================*/
5195:

Line 5211: FROM pn_locations_all

5207: BEGIN
5208:
5209: SELECT location_type_lookup_code,parent_location_id
5210: INTO l_location_type_lookup_code,l_parent_location_id
5211: FROM pn_locations_all
5212: WHERE location_id = p_Location_Id
5213: AND p_as_of_date BETWEEN active_start_date AND active_end_date;
5214:
5215: IF l_location_type_lookup_code IN ('OFFICE','SECTION') THEN

Line 5222: FROM pn_locations_all a,

5218: b.FLOOR,c.location_code building_location_code,c.BUILDING,
5219: prop.property_code,prop.property_name,
5220: d.name office_park_name, e.name region_name
5221: INTO l_location_name_rec
5222: FROM pn_locations_all a,
5223: pn_locations_all b,
5224: pn_locations_all c,
5225: pn_location_parks d,
5226: pn_location_parks e,

Line 5223: pn_locations_all b,

5219: prop.property_code,prop.property_name,
5220: d.name office_park_name, e.name region_name
5221: INTO l_location_name_rec
5222: FROM pn_locations_all a,
5223: pn_locations_all b,
5224: pn_locations_all c,
5225: pn_location_parks d,
5226: pn_location_parks e,
5227: pn_properties_all prop

Line 5224: pn_locations_all c,

5220: d.name office_park_name, e.name region_name
5221: INTO l_location_name_rec
5222: FROM pn_locations_all a,
5223: pn_locations_all b,
5224: pn_locations_all c,
5225: pn_location_parks d,
5226: pn_location_parks e,
5227: pn_properties_all prop
5228: WHERE a.location_id = p_Location_Id

Line 5249: FROM pn_locations_all b,

5245: b.FLOOR,c.location_code building_location_code,c.BUILDING,
5246: prop.property_code,prop.property_name,
5247: d.name office_park_name, e.name region_name
5248: INTO l_location_name_rec
5249: FROM pn_locations_all b,
5250: pn_locations_all c,
5251: pn_location_parks d,
5252: pn_location_parks e,
5253: pn_properties_all prop

Line 5250: pn_locations_all c,

5246: prop.property_code,prop.property_name,
5247: d.name office_park_name, e.name region_name
5248: INTO l_location_name_rec
5249: FROM pn_locations_all b,
5250: pn_locations_all c,
5251: pn_location_parks d,
5252: pn_location_parks e,
5253: pn_properties_all prop
5254: WHERE b.location_id = p_Location_Id

Line 5273: FROM pn_locations_all c,

5269: '' FLOOR,c.location_code building_location_code,c.BUILDING,
5270: prop.property_code,prop.property_name,
5271: d.name office_park_name, e.name region_name
5272: INTO l_location_name_rec
5273: FROM pn_locations_all c,
5274: pn_location_parks d,
5275: pn_location_parks e,
5276: pn_properties_all prop
5277: WHERE c.location_id = p_Location_Id

Line 5417: FROM pn_locations_all

5413: /* Getting rentable area for Office/Section */
5414:
5415: SELECT NVL(rentable_area,0)
5416: INTO l_rentable_area
5417: FROM pn_locations_all
5418: WHERE location_id = p_location_id
5419: AND active_start_date <= l_as_of_date
5420: AND active_end_date >= l_as_of_date;
5421:

Line 5588: FROM pn_locations_all

5584: l_as_of_date DATE := pnp_util_func.get_as_of_date(p_as_of_date);
5585:
5586: CURSOR get_uom_code_cur IS
5587: SELECT uom_code
5588: FROM pn_locations_all
5589: WHERE location_type_lookup_code = l_loc_type
5590: AND l_as_of_date BETWEEN active_start_date AND active_end_date
5591: Start with location_id = p_location_id
5592: CONNECT BY PRIOR parent_location_id = location_id

Line 6280: FROM pn_locations_all

6276: l_fut_str_dt DATE; -- Added for bug#5854636
6277: l_common_flag VARCHAR2(1);
6278: CURSOR get_common_flag IS
6279: SELECT common_area_flag
6280: FROM pn_locations_all
6281: WHERE location_id = p_location_id
6282: AND active_start_date <= l_end_dt
6283: AND active_end_date >= p_st_date;
6284:

Line 6738: FROM pn_locations_all

6734:
6735: CURSOR c_loc is
6736: SELECT NVL(SUM(ASSIGNABLE_AREA),0) , NVL(SUM(RENTABLE_AREA),0) , NVL(SUM(USABLE_AREA),0)
6737: , NVL(SUM(COMMON_AREA),0),NVL(SUM(MAX_CAPACITY),0), NVL(SUM(OPTIMUM_CAPACITY),0)
6738: FROM pn_locations_all
6739: WHERE Location_Type_Lookup_Code = l_location_type_lookup_code
6740: AND Status = 'A'
6741: AND l_as_of_date BETWEEN active_start_date AND active_end_date
6742: START WITH Location_Id = p_Location_Id

Line 6753: FROM pn_locations_all

6749: FROM PN_SPACE_ASSIGN_EMP_ALL
6750: WHERE emp_assign_start_date <= l_as_of_date
6751: AND NVL(emp_assign_end_date, l_date) >= l_as_of_date
6752: AND Location_Id IN (SELECT Location_Id
6753: FROM pn_locations_all
6754: WHERE Location_Type_Lookup_Code = l_location_type_lookup_code
6755: AND Status = 'A'
6756: AND l_as_of_date BETWEEN active_start_date AND active_end_date
6757: START WITH Location_Id = p_Location_Id

Line 6769: FROM pn_locations_all

6765: FROM PN_SPACE_ASSIGN_CUST_ALL
6766: WHERE cust_assign_start_date <= l_as_of_date
6767: AND NVL(cust_assign_end_date, l_date) >= l_as_of_date
6768: AND Location_Id IN (SELECT Location_Id
6769: FROM pn_locations_all
6770: WHERE Location_Type_Lookup_Code = l_location_type_lookup_code
6771: AND Status = 'A'
6772: AND l_as_of_date BETWEEN active_start_date AND active_end_date
6773: START WITH Location_Id = p_Location_Id

Line 7104: FROM pn_locations_all

7100: SELECT *
7101: FROM pn_space_assign_cust_all
7102: WHERE location_id IN
7103: ( SELECT location_id
7104: FROM pn_locations_all
7105: START WITH location_id = p_location_id
7106: CONNECT BY PRIOR location_id = parent_location_id )
7107: AND NVL(cust_assign_end_date,g_end_of_time) >= p_start_date
7108: AND cust_assign_start_date <= NVL(p_end_date, g_end_of_time);

Line 7116: FROM pn_locations_all

7112: SELECT *
7113: FROM pn_space_assign_emp_all
7114: WHERE location_id IN
7115: ( SELECT location_id
7116: FROM pn_locations_all
7117: START WITH location_id = p_location_id
7118: CONNECT BY PRIOR location_id = parent_location_id )
7119: AND NVL(emp_assign_end_date,g_end_of_time) >= p_start_date
7120: AND emp_assign_start_date <= NVL(p_end_date, g_end_of_time);

Line 7270: FROM pn_locations_all

7266: FROM DUAL
7267: WHERE EXISTS (SELECT 'x'
7268: FROM pn_space_assign_emp_all
7269: WHERE location_id IN (SELECT location_id
7270: FROM pn_locations_all
7271: START WITH location_id = p_location_id
7272: CONNECT BY PRIOR location_id = parent_location_id )
7273: --Bug#5959164 AND allocated_area > 0
7274: --Bug#5959164 AND allocated_area_pct > 0

Line 7281: FROM pn_locations_all

7277: UNION
7278: SELECT 'x'
7279: FROM pn_space_assign_cust_all
7280: WHERE location_id IN (SELECT location_id
7281: FROM pn_locations_all
7282: START WITH location_id = p_location_id
7283: CONNECT BY PRIOR location_id = parent_location_id )
7284: --Bug#5959164 AND allocated_area > 0
7285: --Bug#5959164 AND allocated_area_pct > 0

Line 7295: FROM pn_locations_all

7291: FROM DUAL
7292: WHERE EXISTS (SELECT 'x'
7293: FROM pn_space_assign_emp_all
7294: WHERE location_id IN (SELECT location_id
7295: FROM pn_locations_all
7296: START WITH location_id = p_location_id
7297: CONNECT BY PRIOR location_id = parent_location_id )
7298: --Bug#5959164 AND allocated_area > 0
7299: --Bug#5959164 AND allocated_area_pct > 0

Line 7306: FROM pn_locations_all

7302: UNION
7303: SELECT 'x'
7304: FROM pn_space_assign_cust_all
7305: WHERE location_id IN (SELECT location_id
7306: FROM pn_locations_all
7307: START WITH location_id = p_location_id
7308: CONNECT BY PRIOR location_id = parent_location_id )
7309: --Bug#5959164 AND allocated_area > 0
7310: --Bug#5959164 AND allocated_area_pct > 0

Line 7587: FROM pn_locations_all

7583: l_str_date_old DATE;
7584:
7585: CURSOR pn_location_cursor IS
7586: SELECT *
7587: FROM pn_locations_all
7588: WHERE location_id = p_location_id
7589: AND active_start_date = p_Active_start_date_old
7590: AND active_end_date = p_active_end_date_old;
7591:

Line 7718: FROM pn_locations_all

7714: /* Bug#7666462 : Modified the Cursor SELECT query to handle NULL condition for end date */
7715:
7716: CURSOR locations_cursor Is
7717: SELECT *
7718: FROM pn_locations_all
7719: WHERE location_id = p_location_id
7720: AND (active_start_date <= NVL(p_start_Date, active_start_date)
7721: AND nvl(active_end_Date, TO_DATE('12/31/4712','MM/DD/YYYY')) >=
7722: nvl( p_end_date, TO_DATE('12/31/4712','MM/DD/YYYY')));

Line 7768: from pn_locations_all loc

7764: (select tenancy_id
7765: from pn_tenancies_all
7766: where location_id in
7767: (select loc.location_id
7768: from pn_locations_all loc
7769: connect by prior loc.location_id = loc.parent_location_id
7770: start with loc.location_id = p_Location_Id)
7771: and primary_flag = 'Y'
7772: and EXPIRATION_DATE > p_New_End_Date

Line 7814: from pn_locations_all loc

7810: (select tenancy_id
7811: from pn_tenancies_all
7812: where location_id in
7813: (select loc.location_id
7814: from pn_locations_all loc
7815: connect by prior loc.location_id = loc.parent_location_id
7816: start with loc.location_id = p_Location_Id)
7817: and primary_flag = 'Y'
7818: and nvl(OCCUPANCY_DATE,ESTIMATED_OCCUPANCY_DATE) < p_New_Start_Date

Line 7861: from pn_locations_all loc

7857: (select area_class_dtl_line_id
7858: from pn_rec_arcl_dtlln_all
7859: where location_id in
7860: (select loc.location_id
7861: from pn_locations_all loc
7862: connect by prior loc.location_id = loc.parent_location_id
7863: start with loc.location_id = p_Location_Id)
7864: );
7865:

Line 8030: pn_locations_all loc

8026: loc.rentable_area,
8027: loc.usable_area,
8028: loc.assignable_area
8029: FROM pn_payment_terms_all trm,
8030: pn_locations_all loc
8031: WHERE trm.lease_id = p_lease_id
8032: AND loc.location_id = p_loc_id
8033: AND trm.location_id = p_loc_id
8034: AND trm.area_type_code NOT IN ('OTHER')

Line 8261: FROM pn_locations_all

8257: usable_area,
8258: assignable_area,
8259: active_start_date,
8260: active_end_date
8261: FROM pn_locations_all
8262: WHERE location_id = p_ofc_loc_id;
8263:
8264: CURSOR get_affected_payment_terms (p_ofc_id NUMBER, p_flr_id NUMBER, p_bld_id NUMBER,
8265: p_start_date DATE, p_end_date DATE) IS

Line 8288: FROM pn_locations_all loc

8284: CURSOR get_flr_area (p_as_of_date DATE) IS
8285: SELECT sum(nvl(rentable_area,0)) rentable,
8286: sum(nvl(usable_area,0)) usable,
8287: sum(nvl(assignable_area,0)) assignable
8288: FROM pn_locations_all loc
8289: WHERE loc.parent_location_id = p_flr_loc_id
8290: AND p_as_of_date BETWEEN active_start_date AND active_end_date
8291: AND location_id <> p_ofc_loc_id;
8292:

Line 8298: FROM pn_locations_all f, pn_locations_all o

8294: CURSOR get_bld_area (p_as_of_date DATE) IS
8295: SELECT sum(nvl(o.rentable_area,0)) rentable,
8296: sum(nvl(o.usable_area,0)) usable,
8297: sum(nvl(o.assignable_area,0)) assignable
8298: FROM pn_locations_all f, pn_locations_all o
8299: WHERE p_bld_loc_id = f.parent_location_id
8300: AND f.location_id = o.parent_location_id
8301: AND p_as_of_date BETWEEN f.active_start_date AND f.active_end_date
8302: AND p_as_of_date BETWEEN o.active_start_date AND o.active_end_date

Line 8450: FROM pn_locations_all ofc,

8446: nvl(sum(ofc.usable_area),0) usable,
8447: nvl(sum(ofc.assignable_area),0) assignable,
8448: nvl(sum(ofc.max_capacity),0) max_capacity,
8449: nvl(sum(ofc.optimum_capacity),0) optimum_capacity
8450: FROM pn_locations_all ofc,
8451: pn_locations_all flr
8452: WHERE p_as_of_date BETWEEN ofc.active_start_date AND ofc.active_end_date
8453: AND p_as_of_date BETWEEN flr.active_start_date AND flr.active_end_date
8454: AND flr.parent_location_id = p_location_id

Line 8451: pn_locations_all flr

8447: nvl(sum(ofc.assignable_area),0) assignable,
8448: nvl(sum(ofc.max_capacity),0) max_capacity,
8449: nvl(sum(ofc.optimum_capacity),0) optimum_capacity
8450: FROM pn_locations_all ofc,
8451: pn_locations_all flr
8452: WHERE p_as_of_date BETWEEN ofc.active_start_date AND ofc.active_end_date
8453: AND p_as_of_date BETWEEN flr.active_start_date AND flr.active_end_date
8454: AND flr.parent_location_id = p_location_id
8455: AND ofc.parent_location_id = flr.location_id;

Line 8463: FROM pn_locations_all ofc

8459: nvl(sum(ofc.usable_area),0) usable,
8460: nvl(sum(ofc.assignable_area),0) assignable,
8461: nvl(sum(ofc.max_capacity),0) max_capacity,
8462: nvl(sum(ofc.optimum_capacity),0) optimum_capacity
8463: FROM pn_locations_all ofc
8464: WHERE p_as_of_date BETWEEN ofc.active_start_date AND ofc.active_end_date
8465: AND ofc.parent_location_id = p_location_id;
8466:
8467: CURSOR office_area IS

Line 8473: FROM pn_locations_all ofc

8469: usable_area usable,
8470: assignable_area assignable,
8471: max_capacity max_capacity,
8472: optimum_capacity optimum_capacity
8473: FROM pn_locations_all ofc
8474: WHERE p_as_of_date BETWEEN ofc.active_start_date AND ofc.active_end_date
8475: AND ofc.location_id = p_location_id;
8476:
8477: BEGIN