• raja subbu 1
  • NEWBIE
  • 30 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 7
    Replies
 for(Contact c:[selectid,accountid,phone,mailingstreet,mailingcity,mailingpostalcode,mailingcountry,mailingstate fromcontact where accountid in :trigger.new]) {
    account a = trigger.newmap.get(c.accountid);
    boolean updatedrecord = false;
   if(c.phone == trigger.oldmap.get(c.accountid).phone) {
      c.phone = a.phone;
      updatedrecord = true;
    }
trigger actrig on position1__c (after insert) {
    list<candidate1__c> candlist=new list<candidate1__c>();
    map<id,position1__c> mymap=new map<id,position1__c>();
list<candidate1__c> canlist=[select id,email__c,position1__c from candidate1__c where position1__c=:mymap.keyset()];
    for(candidate1__c ca:canlist){
      ca.email__c=mymap.get(ca.position1__c).email__c; 
        candlist.add(ca);
        
    }
    
    update candlist;
    
    
}
this is my code 

trigger trigb23 on position1__c (after update) {
     list<candidate1__c> clist=new list<candidate1__c>();
   
    for(position1__c p:trigger.new){
        
            
        list<candidate1__c> cnd=[select id,name,position1__c from candidate1__c where position1__c=:p.id];
        
        candidate1__c c=new candidate1__c();
        c.position1__c=p.Id;
        c.email__c=p.email__c;
        clist.add(c);

    }
    update clist;
    
}
this is my code

trigger trg12 on data__c (before insert) {
list<data__c>stu=trigger.new;
    for(data__c s:trigger.new){
        if(s.country__c='usa') {
            double p;
            p=s.fee__c*0.2;
            s.fee__c =s.fee__c - p;
        }
        
        
    } 
trigger actrig on position1__c (after insert) {
    list<candidate1__c> candlist=new list<candidate1__c>();
    map<id,position1__c> mymap=new map<id,position1__c>();
list<candidate1__c> canlist=[select id,email__c,position1__c from candidate1__c where position1__c=:mymap.keyset()];
    for(candidate1__c ca:canlist){
      ca.email__c=mymap.get(ca.position1__c).email__c; 
        candlist.add(ca);
        
    }
    
    update candlist;
    
    
}
this is my code 

trigger trigb23 on position1__c (after update) {
     list<candidate1__c> clist=new list<candidate1__c>();
   
    for(position1__c p:trigger.new){
        
            
        list<candidate1__c> cnd=[select id,name,position1__c from candidate1__c where position1__c=:p.id];
        
        candidate1__c c=new candidate1__c();
        c.position1__c=p.Id;
        c.email__c=p.email__c;
        clist.add(c);

    }
    update clist;
    
}
this is my code

trigger trg12 on data__c (before insert) {
list<data__c>stu=trigger.new;
    for(data__c s:trigger.new){
        if(s.country__c='usa') {
            double p;
            p=s.fee__c*0.2;
            s.fee__c =s.fee__c - p;
        }
        
        
    }