DBA Data[Home] [Help]

APPS.ARP_APP_CALC_PKG SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 47

   select nvl(rule_set_id,nvl(arp_standard.sysparm.rule_set_id,-1))
   into l_rule_set_id
   from ra_cust_trx_types
   where cust_trx_type_id = p_trx_type_id ;
Line: 118

    select rule_source
    into l_rule_source_lng
    from ar_app_rule_sets
    where rule_set_id = p_rule_set_id ;
Line: 780

	 * schedule's line_remaining was not getting updated correctly.
	 * Assigning zero to null amount parameters.
	 */
	p_line_remaining 	:= nvl(p_line_remaining, 0);
Line: 1080

 |  inserted into                                                            |
 |  the ar_app_rule_sets table with the according rule                       |
 |  This compilation makes it possible for the calc_applied_and_remaining    |
 |  procedure not to select multiple times from app_rule... tables           |
 |                                                                           |
 |  This procedure should be called from the application rules set up form   |
 |  from the post_update trigger when the freeze flag gets  set to 'Y'       |
 |                                                                           |
 |  Whenever a rule will be frozen a compiled rule will be created and stored|
 |  in the long           column rule_source.                                |
 |                                                                           |
 |  Before creating the long  column the procedure will check whether        |
 |  the rule is valid. Following checks will be made :                       |
 |    1. Is there one and only one Over Application Rule                     |
 |    2. Are there one or more non-overapplication Rules                     |
 |    3. Is every Line type present in one of the non-overapplication rules  |
 |    4. Has one and only one of the application rule details in every       |
 |       application rule  the rounding correction checked                   |
 |    5. Are the sequence numbers of the application rules  different        |
 |                                                                           |
 |                                                                           |
 |  SCOPE -- Public -- To be called from the application rules set up form   |
 |  PARAMETERS                                                               |
 |     IN -- rule_id -- This is the id from the rule you want to compile.    |
 | RULE_SOURCE (Example Code )
 | -----------
 | DECLARE  Rule Name : Pro Ratio
 | Date Generated : 20-MAR-1997,15:15
 | 1. Pro Ratio Rule
 |      LINE, PRORATE , Rounding Correction : Y
 |      FREIGHT, NONE , Rounding Correction : N
 |      CHARGES, NONE , Rounding Correction : N
 |  Over Application Rule : Pro Ratio Over App
 |      LINE, PRORATE , Rounding Correction : Y
 |      FREIGHT, NONE , Rounding Correction : N
 |      CHARGES, NONE , Rounding Correction : N
 |
 |  l_amt ar_payment_schedules.amount_due_remaining%TYPE;
Line: 1212

select rule_set_name
from ar_app_rule_sets
where rule_set_id = p_rule_set_id;
Line: 1217

select rule_name, rule_id,rule_sequence
from ar_app_rules
where rule_set_id = p_rule_set_id
order by rule_sequence;
Line: 1223

select rule_name, rule_id,rule_sequence
from ar_app_rules
where rule_set_id = p_rule_set_id
and overapp_flag = 'N'
order by rule_sequence;
Line: 1230

select rule_name, rule_id,rule_sequence
from ar_app_rules
where rule_set_id = p_rule_set_id
and overapp_flag = 'Y' ;
Line: 1236

select rule_detail_id , line_type , rounding_correction_flag , tax_treatment
from ar_app_rule_details
where rule_id = p_rule_id ;
Line: 1241

select rule_detail_id , line_type , rounding_correction_flag , tax_treatment
from ar_app_rule_details
where rule_id = p_rule_id
and rounding_correction_flag = 'Y';
Line: 1247

select rule_detail_id , line_type , rounding_correction_flag , tax_treatment
from ar_app_rule_details
where rule_id = p_rule_id
and rounding_correction_flag <> 'Y';
Line: 1253

select rule_detail_id , line_type , rounding_correction_flag , tax_treatment
from ar_app_rule_details
where rule_id = p_rule_id;
Line: 1540

     * ar_payment_schedules is populated is 0. As a result updates in ar_payment_schedules
     * are incorrect.
     * Fix is to remove the condition 'and ((l_line_remaining >0) OR (l_freight_remaining >0)
     * OR (l_charges_remaining >0))' introduced as part of bug fix 840642, while retaining the
     * fix made for bug 973520. Such a fix would resolve all three bugs 840642, 973520 and 1105018.
     */

     l_source := l_source || '
    if (l_amt > 0)then
       ' ;
Line: 1699

    update ar_app_rule_sets
    set rule_source = l_source
     ,  last_updated_by = fnd_global.user_id
     ,  last_update_date = sysdate
     ,  last_update_login = fnd_global.login_id
    where rule_set_id = p_rule_set_id;