+ Start a Discussion

tracking history not working on one field

I have history tracking set for a custom field called Button Clicked on a custom object Change.  I have the field being updated through a Propose a Change button.  If a Dealer portal user clicks the buttton, the history gets updated and last modified gets updated.  If a Customer Portal User clicks the button the history doesn't get updated and the last modified date doesn't get updated.  I can't for the life of me see a difference between the 2 profiles except for the fact they are 2 different licenses.  Any ideas?
HI Staci, 

How is the field getting updated based on the Action (Click Button)? 

Also enable debug logs for the users and see if you notice any change. 

Yes its based on the button click
Here's the log
08:30:17.105 (105629000)|EXECUTION_STARTED
08:30:17.105 (105684000)|CODE_UNIT_STARTED|[EXTERNAL]|06630000000kUfJ|VF: /apex/DisplayLogo
08:30:17.107 (107544000)|CODE_UNIT_STARTED|[EXTERNAL]|01p30000000iGHQ|DealerLogoController1 <init>
08:30:17.107 (107565000)|SYSTEM_MODE_ENTER|true
08:30:17.108 (108462000)|METHOD_ENTRY|[1]|01p30000000iGHQ|DealerLogoController1.DealerLogoController1()
08:30:17.108 (108475000)|METHOD_EXIT|[1]|DealerLogoController1
08:30:17.108 (108647000)|SYSTEM_METHOD_ENTRY|[3]|system.UserInfo.getUserId()
08:30:17.108 (108749000)|SYSTEM_METHOD_EXIT|[3]|system.UserInfo.getUserId()
08:30:17.109 (109076000)|SOQL_EXECUTE_BEGIN|[3]|Aggregations:0|select id, contactId, Contact.AccountId from User where id = :tmpVar1
08:30:17.209 (209643000)|SOQL_EXECUTE_END|[3]|Rows:1
08:30:17.209 (209991000)|CODE_UNIT_FINISHED|DealerLogoController1 <init>
08:30:17.210 (210065000)|CODE_UNIT_STARTED|[EXTERNAL]|01p30000000iGHQ|DealerLogoController1 get(LogoURL)
08:30:17.210 (210079000)|SYSTEM_MODE_ENTER|true
08:30:17.210 (210106000)|CODE_UNIT_STARTED|[EXTERNAL]|01p30000000iGHQ|DealerLogoController1 invoke(getLogoURL)
08:30:17.210 (210477000)|SOQL_EXECUTE_BEGIN|[17]|Aggregations:0|select Id, Account.Logo_URL__c from Contact where Id = :tmpVar1 limit 1
08:30:17.243 (243584000)|SOQL_EXECUTE_END|[17]|Rows:1
08:30:17.243 (243844000)|SYSTEM_METHOD_ENTRY|[21]|System.debug(ANY)
08:30:17.243 (243879000)|USER_DEBUG|[21]|DEBUG|URL: http://www.westrac.com.au/_layouts/images/westrac.internet/westrac.gif
08:30:17.243 (243891000)|SYSTEM_METHOD_EXIT|[21]|System.debug(ANY)
08:30:17.243 (243919000)|SYSTEM_METHOD_ENTRY|[22]|LIST<Contact>.isEmpty()
08:30:17.243 (243943000)|SYSTEM_METHOD_EXIT|[22]|LIST<Contact>.isEmpty()
08:30:17.243 (243978000)|CODE_UNIT_FINISHED|DealerLogoController1 invoke(getLogoURL)
08:30:17.243 (243994000)|CODE_UNIT_FINISHED|DealerLogoController1 get(LogoURL)
08:30:17.465 (247761000)|CUMULATIVE_LIMIT_USAGE
  Number of SOQL queries: 2 out of 100
  Number of query rows: 2 out of 50000
  Number of SOSL queries: 0 out of 20
  Number of DML statements: 0 out of 150
  Number of DML rows: 0 out of 10000
  Maximum CPU time: 0 out of 10000
  Maximum heap size: 0 out of 6000000
  Number of callouts: 0 out of 10
  Number of Email Invocations: 0 out of 10
  Number of fields describes: 0 out of 100
  Number of record type describes: 0 out of 100
  Number of child relationships describes: 0 out of 100
  Number of picklist describes: 0 out of 100
  Number of future calls: 0 out of 10


08:30:17.247 (247797000)|CODE_UNIT_FINISHED|VF: /apex/DisplayLogo
08:30:17.247 (247813000)|EXECUTION_FINISHED

Here's the button code:

var changeObj = new sforce.SObject("Change__c");
changeObj.Id = '{!Change__c.Id}';

changeObj.Propose_Change_Button_Clicked__c = "Change proposed";

var result = sforce.connection.update([changeObj]);

if (result[0].success=='false')
alert("Error:" + result + " " + changeObj.Id + " " + changeObj.Propose_Change_Button_Clicked__c);
alert("Thank you. Your change has been submitted.");

Hi , 

The trigger is definately firing for the Portal user as well as per the logs there is something that is missing for the Portal license. 

What license is given to This particular user - can you try changing it to High Volume Portal user and try again and observe. 

See agian if the Portal user is missing some related object access. 

Also See the discussion in the thread below,