DBA Data[Home] [Help]

APPS.AR_CMGT_WF_ENGINE dependencies on HZ_CUSTOMER_PROFILES

Line 660: hz_customer_profiles prof

656: l_profile_class_name, l_postal_code, l_state, l_party_id
657: FROM ar_cmgt_credit_requests c,
658: hz_parties p,
659: hz_cust_profile_classes profclass,
660: hz_customer_profiles prof
661: WHERE c.credit_request_id = p_credit_request_id
662: AND c.party_id = p.party_id
663: AND p.party_id = prof.party_id
664: AND c.cust_account_id = decode(prof.cust_account_id,-1,-99,prof.cust_account_id)

Line 740: FROM hz_customer_profiles a, ar_cmgt_credit_requests b

736: THEN
737: BEGIN
738: SELECT a.CREDIT_ANALYST_ID
739: INTO l_credit_analyst_id
740: FROM hz_customer_profiles a, ar_cmgt_credit_requests b
741: WHERE b.credit_request_id = itemkey
742: AND a.party_id = b.party_id
743: AND a.cust_account_id = decode(b.cust_account_id,-99,-1,b.cust_account_id)
744: AND nvl(a.site_use_id,-99) = nvl(b.site_use_id, -99);

Line 1108: l_cust_account_profile_id hz_customer_profiles.cust_account_profile_id%type;

1104: funcmode in varchar2,
1105: resultout out NOCOPY varchar2) IS
1106:
1107: l_party_id ar_cmgt_credit_requests.party_id%type;
1108: l_cust_account_profile_id hz_customer_profiles.cust_account_profile_id%type;
1109: BEGIN
1110: -- need to check and if not exists then craeet party profile(ARCMHZCB.pls AR_CMGT_HZ_COVER_API)
1111: IF funcmode = 'RUN'
1112: THEN

Line 1118: -- then do n't create else create a record in hz_customer_profiles

1114: INTO l_party_id
1115: FROM ar_cmgt_credit_requests
1116: WHERE credit_request_id = itemkey;
1117: -- furst check whether the profile record exists or not. if exists
1118: -- then do n't create else create a record in hz_customer_profiles
1119: WF_ENGINE.setItemAttrNumber(itemtype => itemtype,
1120: itemkey => itemkey,
1121: aname => 'PARTY_ID',
1122: avalue => l_party_id);

Line 1126: FROM hz_customer_profiles

1122: avalue => l_party_id);
1123: BEGIN
1124: SELECT cust_account_profile_id
1125: INTO l_cust_account_profile_id
1126: FROM hz_customer_profiles
1127: WHERE party_id = l_party_id
1128: AND cust_account_id = -1
1129: AND site_use_id IS NULL;
1130:

Line 2267: ' UPDATE hz_customer_profiles ' ||

2263: THEN
2264: IF p_site_use_id IS NULL
2265: THEN
2266: l_sql_statement :=
2267: ' UPDATE hz_customer_profiles ' ||
2268: ' set credit_classification = :1 ,'||
2269: ' last_update_date = sysdate ,'||
2270: ' last_updated_by = fnd_global.user_id, '||
2271: ' last_update_login = fnd_global.login_id '||

Line 2282: ' UPDATE hz_customer_profiles ' ||

2278: p_cust_account_id;
2279: ELSIF p_site_use_id IS NOT NULL
2280: THEN
2281: l_sql_statement :=
2282: ' UPDATE hz_customer_profiles ' ||
2283: ' set credit_classification = :1, '||
2284: ' last_update_date = sysdate ,'||
2285: ' last_updated_by = fnd_global.user_id, '||
2286: ' last_update_login = fnd_global.login_id '||

Line 2307: from hz_customer_profiles

2303: last_updated_by = fnd_global.user_id,
2304: last_update_login = fnd_global.login_id
2305: WHERE cust_account_profile_id = (
2306: select cust_account_profile_id
2307: from hz_customer_profiles
2308: WHERE party_id = p_party_id
2309: AND cust_account_id = p_cust_account_id
2310: AND site_use_id IS NULL )
2311: AND currency_code = p_reco_value1;

Line 2321: from hz_customer_profiles

2317: last_updated_by = fnd_global.user_id,
2318: last_update_login = fnd_global.login_id
2319: WHERE cust_account_profile_id = (
2320: select cust_account_profile_id
2321: from hz_customer_profiles
2322: WHERE party_id = p_party_id
2323: AND cust_account_id = p_cust_account_id
2324: AND site_use_id = p_site_use_id )
2325: AND currency_code = p_reco_value1;

Line 2338: from hz_customer_profiles

2334: last_updated_by = fnd_global.user_id,
2335: last_update_login = fnd_global.login_id
2336: WHERE cust_account_profile_id = (
2337: select cust_account_profile_id
2338: from hz_customer_profiles
2339: WHERE party_id = p_party_id
2340: AND cust_account_id = p_cust_account_id
2341: AND site_use_id IS NULL )
2342: AND currency_code = p_reco_value1;

Line 2352: from hz_customer_profiles

2348: last_updated_by = fnd_global.user_id,
2349: last_update_login = fnd_global.login_id
2350: WHERE cust_account_profile_id = (
2351: select cust_account_profile_id
2352: from hz_customer_profiles
2353: WHERE party_id = p_party_id
2354: AND cust_account_id = p_cust_account_id
2355: AND site_use_id = p_site_use_id )
2356: AND currency_code = p_reco_value1;

Line 2362: UPDATE hz_customer_profiles

2358: ELSIF p_credit_recommendation = 'CUST_HOLD'
2359: THEN
2360: IF p_site_use_id IS NULL
2361: THEN
2362: UPDATE hz_customer_profiles
2363: set credit_hold = 'Y',
2364: last_update_date = sysdate,
2365: last_updated_by = fnd_global.user_id,
2366: last_update_login = fnd_global.login_id

Line 2372: UPDATE hz_customer_profiles

2368: AND cust_account_id = p_cust_account_id
2369: AND site_use_id IS NULL;
2370: ELSIF p_site_use_id IS NOT NULL
2371: THEN
2372: UPDATE hz_customer_profiles
2373: set credit_hold = 'Y',
2374: last_update_date = sysdate,
2375: last_updated_by = fnd_global.user_id,
2376: last_update_login = fnd_global.login_id

Line 2386: UPDATE hz_customer_profiles

2382: ELSIF p_credit_recommendation = 'REMOVE_CUST_HOLD'
2383: THEN
2384: IF p_site_use_id IS NULL
2385: THEN
2386: UPDATE hz_customer_profiles
2387: set credit_hold = 'N',
2388: last_update_date = sysdate,
2389: last_updated_by = fnd_global.user_id,
2390: last_update_login = fnd_global.login_id

Line 2396: UPDATE hz_customer_profiles

2392: AND cust_account_id = p_cust_account_id
2393: AND site_use_id IS NULL;
2394: ELSIF p_site_use_id IS NOT NULL
2395: THEN
2396: UPDATE hz_customer_profiles
2397: set credit_hold = 'N',
2398: last_update_date = sysdate,
2399: last_updated_by = fnd_global.user_id,
2400: last_update_login = fnd_global.login_id

Line 2417: from hz_customer_profiles

2413: last_updated_by = fnd_global.user_id,
2414: last_update_login = fnd_global.login_id
2415: WHERE cust_account_profile_id = (
2416: select cust_account_profile_id
2417: from hz_customer_profiles
2418: WHERE party_id = p_party_id
2419: AND cust_account_id = p_cust_account_id
2420: AND site_use_id IS NULL )
2421: AND currency_code = p_reco_value1;

Line 2432: from hz_customer_profiles

2428: last_updated_by = fnd_global.user_id,
2429: last_update_login = fnd_global.login_id
2430: WHERE cust_account_profile_id = (
2431: select cust_account_profile_id
2432: from hz_customer_profiles
2433: WHERE party_id = p_party_id
2434: AND cust_account_id = p_cust_account_id
2435: AND site_use_id = p_site_use_id )
2436: AND currency_code = p_reco_value1;

Line 2450: from hz_customer_profiles

2446: last_updated_by = fnd_global.user_id,
2447: last_update_login = fnd_global.login_id
2448: WHERE cust_account_profile_id = (
2449: select cust_account_profile_id
2450: from hz_customer_profiles
2451: WHERE party_id = p_party_id
2452: AND cust_account_id = p_cust_account_id
2453: AND site_use_id IS NULL )
2454: AND currency_code = p_reco_value1;

Line 2465: from hz_customer_profiles

2461: last_updated_by = fnd_global.user_id,
2462: last_update_login = fnd_global.login_id
2463: WHERE cust_account_profile_id = (
2464: select cust_account_profile_id
2465: from hz_customer_profiles
2466: WHERE party_id = p_party_id
2467: AND cust_account_id = p_cust_account_id
2468: AND site_use_id = p_site_use_id )
2469: AND currency_code = p_reco_value1;

Line 2771: l_last_revw_date hz_customer_profiles.LAST_CREDIT_REVIEW_DATE%TYPE;

2767: HOLD_ERROR EXCEPTION;
2768: l_reco_id ar_cmgt_cf_recommends.RECOMMENDATION_ID%TYPE;
2769: l_dayz ar_cmgt_cf_recommends.RECOMMENDATION_VALUE1%TYPE;
2770: no_data_found EXCEPTION;
2771: l_last_revw_date hz_customer_profiles.LAST_CREDIT_REVIEW_DATE%TYPE;
2772:
2773: CURSOR c_reco IS
2774: SELECT credit_recommendation, recommendation_value1,
2775: recommendation_value2

Line 2917: FROM hz_customer_profiles

2913: BEGIN
2914:
2915: SELECT LAST_CREDIT_REVIEW_DATE
2916: INTO l_last_revw_date
2917: FROM hz_customer_profiles
2918: WHERE party_id = l_party_id
2919: AND cust_account_id = l_cust_account_id
2920: AND site_use_id IS NULL;
2921:

Line 2944: UPDATE hz_customer_profiles

2940: IF l_last_revw_date IS NOT NULL
2941: THEN
2942: BEGIN
2943:
2944: UPDATE hz_customer_profiles
2945: SET REVIEW_CYCLE = c_reco_rec.recommendation_value1,
2946: NEXT_CREDIT_REVIEW_DATE = DECODE(c_reco_rec.recommendation_value1,
2947: 'YEARLY', (l_last_revw_date + 365),
2948: 'HALF_YEARLY', (l_last_revw_date + 180),

Line 2985: FROM hz_customer_profiles

2981: BEGIN
2982:
2983: SELECT LAST_CREDIT_REVIEW_DATE
2984: INTO l_last_revw_date
2985: FROM hz_customer_profiles
2986: WHERE party_id = l_party_id
2987: AND cust_account_id = l_cust_account_id
2988: AND site_use_id = l_site_use_id;
2989:

Line 3013: UPDATE hz_customer_profiles

3009: IF l_last_revw_date IS NOT NULL
3010: THEN
3011: BEGIN
3012:
3013: UPDATE hz_customer_profiles
3014: SET REVIEW_CYCLE = c_reco_rec.recommendation_value1,
3015: NEXT_CREDIT_REVIEW_DATE = DECODE(review_cycle,
3016: 'YEARLY', (l_last_revw_date + 365),
3017: 'HALF_YEARLY', (l_last_revw_date + 180),

Line 3138: FROM hz_customer_profiles

3134: INTO l_credit_limit
3135: FROM hz_cust_profile_amts hzp
3136: WHERE cust_account_profile_id = (
3137: SELECT cust_account_profile_id
3138: FROM hz_customer_profiles
3139: WHERE party_id = l_party_id
3140: AND cust_account_id = l_cust_account_id
3141: AND ( site_use_id IS NULL
3142: OR site_use_id = l_site_use_id))