• baaskar
  • NEWBIE
  • 0 Points
  • Member since 2010

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 0
    Replies

I am getting incorrect previousFireTime value for the newly shceduled job. It shows future time for example (---lastSchTime---2010-07-06 11:35:00) while it was scheduled at 07:35:00 am.

 

This is part of the scheduled class code

 

global void execute(SchedulableContext sc) {

    CronTrigger cronTrig = [Select id,PreviousFireTime,timesTriggered from CronTrigger where id=:sc.getTriggerId()];

    Datetime lastSchTime = cronTrig.PreviousFireTime;

    //List the Accnt team members which are modified after the last scheduled time.
                List<AccountTeamMember> latestUpdatedATMList = [Select id,userId,accountId,LastModifiedDate   
                        from AccountTeamMember where LastModifiedDate >: lastSchTime];

    ......

 

But still it is not fetching the recently modified account team member details (atestUpdatedATMList), since
previousfiretime field retrived as future date.

 

Can anyone help me out, if i coded incorrectly.

 

Regards,

baaskar

I am using the StandardSetController class for one of the page in my org. I able to fetch data from the force.com DB. Pagination also was working fine till I try to implement custom sorting function for the table data. Either one of the functions is not working at the same time. Can anyone help me out of this issue. Is there any default method available to sort table data using the StandardSetController class.

 

Thanks in advance.

 

baaskar subramanian