Thank you for supporting the Cloud Customer Connect Community in 2024. It's a gift to work with you!

Look back
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Script always takes first condition

edited Jan 22, 2019 5:32PM in Sales 2 comments

Content

Hi, 
  
In Before Update when I use the below code always the first conditoin only executes  
  
  
condition1 ; 
  
if (isAttributeChanged('EstimatedTotal_c') && (EstimatedTotal_c <50000)) 
{ 
  throw new oracle.jbo.ValidationException('VAT') 
  WorkflowFlag_c = 'PPB_DS_L50K_16' 
   
} 
  
condition 2; 
  
if ((isAttributeChanged('EstimatedTotal_c') && (EstimatedTotal_c <50000)) 
  && (isAttributeChanged('DataAccessBySupplier_c') && (DataAccessBySupplier_c =='Y'))) 
{ 
  throw new oracle.jbo.ValidationException('TECH') 
  WorkflowFlag_c = 'PPB_DS_L50K_146' 
} 

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!