96:
97: l_stmt_num := 60;
98: IF (p_organization_id IS NULL) THEN
99:
100: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
101: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
102: fnd_msg_pub.add;
103: RAISE fnd_api.g_exc_error;
104: END IF;
97: l_stmt_num := 60;
98: IF (p_organization_id IS NULL) THEN
99:
100: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
101: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
102: fnd_msg_pub.add;
103: RAISE fnd_api.g_exc_error;
104: END IF;
105:
110: FETCH c_org_code INTO l_organization_code;
111:
112: IF (c_org_code%NOTFOUND) THEN
113:
114: fnd_message.set_name('EAM', 'EAM_ORG_CODE_NULL');
115: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
116: fnd_msg_pub.add;
117: RAISE fnd_api.g_exc_error;
118: END IF;
111:
112: IF (c_org_code%NOTFOUND) THEN
113:
114: fnd_message.set_name('EAM', 'EAM_ORG_CODE_NULL');
115: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
116: fnd_msg_pub.add;
117: RAISE fnd_api.g_exc_error;
118: END IF;
119: CLOSE c_org_code;
212:
213: l_stmt_num := 60;
214: IF (p_organization_id IS NULL OR p_concatenated_segments IS NULL) THEN
215:
216: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
217: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
218: fnd_msg_pub.add;
219: RAISE fnd_api.g_exc_error;
220: END IF;
213: l_stmt_num := 60;
214: IF (p_organization_id IS NULL OR p_concatenated_segments IS NULL) THEN
215:
216: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
217: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
218: fnd_msg_pub.add;
219: RAISE fnd_api.g_exc_error;
220: END IF;
221:
331:
332: l_stmt_num := 60;
333: IF (p_organization_id IS NULL) THEN
334:
335: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
336: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
337: fnd_msg_pub.add;
338: RAISE fnd_api.g_exc_error;
339: END IF;
332: l_stmt_num := 60;
333: IF (p_organization_id IS NULL) THEN
334:
335: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
336: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
337: fnd_msg_pub.add;
338: RAISE fnd_api.g_exc_error;
339: END IF;
340:
448:
449: l_stmt_num := 60;
450: IF (p_organization_id IS NULL) THEN
451:
452: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
453: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
454: fnd_msg_pub.add;
455: RAISE fnd_api.g_exc_error;
456: END IF;
449: l_stmt_num := 60;
450: IF (p_organization_id IS NULL) THEN
451:
452: fnd_message.set_name('EAM', 'EAM_INPUT_PARAMS_NULL');
453: fnd_message.set_token('EAM_DEBUG',l_full_name||'('||l_stmt_num||')');
454: fnd_msg_pub.add;
455: RAISE fnd_api.g_exc_error;
456: END IF;
457:
2474: l_hr_exists := 'N';
2475: end;
2476:
2477: if (l_hr_exists = 'Y') then
2478: fnd_message.set_name('EAM','EAM_HIERARCHY_EXISTS');
2479: fnd_msg_pub.add;
2480: RAISE fnd_api.g_exc_error;
2481: end if;
2482:
2499: end;
2500:
2501:
2502: if (nvl(l_routes_exists,'N') = 'Y') then
2503: fnd_message.set_name('EAM','EAM_ROUTE_EXISTS');
2504: fnd_msg_pub.add;
2505: RAISE fnd_api.g_exc_error;
2506: end if;
2507:
2529: l_wo_exists := 'N';
2530: end;
2531:
2532: if (nvl(l_wo_exists,'N') = 'Y') then
2533: fnd_message.set_name('EAM','EAM_WO_EXISTS');
2534: fnd_msg_pub.add;
2535: RAISE fnd_api.g_exc_error;
2536: end if;
2537:
2554: l_sr_exists := 'N';
2555: end;
2556:
2557: if (nvl(l_sr_exists,'N') = 'Y') then
2558: fnd_message.set_name('EAM','EAM_SR_EXISTS');
2559: fnd_msg_pub.add;
2560: RAISE fnd_api.g_exc_error;
2561: end if;
2562: eam_asset_number_pvt.update_asset(
3191: l_hr_exists := 'N';
3192: end;
3193:
3194: if (l_hr_exists = 'Y') then
3195: fnd_message.set_name('EAM','EAM_HIERARCHY_EXISTS');
3196: fnd_msg_pub.add;
3197: l_result := false;
3198:
3199: end if;
3217: end;
3218:
3219:
3220: if (l_routes_exists = 'Y') then
3221: fnd_message.set_name('EAM','EAM_ROUTE_EXISTS');
3222: fnd_msg_pub.add;
3223: l_result := false;
3224: end if;
3225:
3248: l_wo_exists := 'N';
3249: end;
3250:
3251: if (l_wo_exists = 'Y') then
3252: fnd_message.set_name('EAM','EAM_WO_EXISTS');
3253: fnd_msg_pub.add;
3254: l_result := false;
3255: end if;
3256:
3268: l_network_asset_flag := 'N';
3269: end;
3270:
3271: if (l_network_asset_flag = 'Y') then
3272: fnd_message.set_name('EAM','EAM_ROUTE_DEACTIVATE');
3273: fnd_msg_pub.add;
3274: l_result := false;
3275: end if;
3276: