+ Start a Discussion
Keer YenduriKeer Yenduri 

Error explanation

I need that program solution plz helpme out
Swagato RaySwagato Ray
Explain the problem
Keer YenduriKeer Yenduri
trigger compa_Rision on Account(before update)
{
    for(Account acc : Trigger.new)
    {
    Account oldAccount = Trigger.oldMap.get(acc.ID)
        if(acc.AccountNumber!=oldAccount.AccountNumber)
        {
        System.debug('Account number is changed');
       System.debug('**Old Account Number :' + oldAccount.AccountNumber);
           System.debug('**New Account Number :' + acc.AccountNumber);
        acc.Type = 'prospect';
        }
        else
        {
        System.debug('number has not been changed');
        acc.Type = 'other';
        }

    }
}

i got the error like:
Compile Error: unexpected token: 'trigger' at line 1 column 0