• pbulacz
  • NEWBIE
  • 25 Points
  • Member since 2009

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

This can't be right can it?

 

I just got this error... 

 

 Error: List controllers are not supported for CampaignMember

 

 

All I want is a paginated list display of CampaignMember records...

 

In reality I would love an enhances list of CampaignMember records but I can't do that... Any ideas. 

 

I need to work with this object specifically.

 

update: <apex:listViews type="CampaignMember" /> works but won't suffice as I need to be able to specify what type of element is displayed in the list.

 

As it's an 'editable' grid like list I need to create.

Message Edited by pbulacz on 10-19-2009 05:45 PM

I have a before insert / before update trigger on event that does some calculations and uses the StartDateTime and EndDateTime fields for it's processing.

 

Now all works fine for single events (i.e. 1 off events not part of a series).

 

However when I try and UPDATE an event that is part of a series the startdatetime and enddatetime appear wrong, and are ruining my results.

 

This only happens on UPDATE, for insert of a recurring series everything calculates fine, but when I just try and edit only one of the events in a series the startDateTime get skewed.

 

Any Ideas? Is it somehow based on system time vs the local time settings of the org or something like that?

 

My startdatetime SHOULD BE

START =2009-06-15 08:30:00  END =2009-06-16 17:30:00
But as you can see in the Debug log excerpt below the start and end times are completely skewed!!

20090611063904.439:Trigger.Event_Before_Update: line 55, column 9: INITIAL START =2009-06-15 22:30:00
20090611063904.439:Trigger.Event_Before_Update: line 56, column 9: INITIAL END =2009-06-16 07:30:00

 Debugging a single event that isn't part of a series doesn't shed much light either as the start and end time/date is STILL SKEWED however for some reason the code processes it fine???

 

This ones a bit confusing any help would be great.

 

 

Message Edited by pbulacz on 06-10-2009 11:58 PM
Message Edited by pbulacz on 06-11-2009 04:12 PM
Message Edited by pbulacz on 06-11-2009 04:13 PM

This can't be right can it?

 

I just got this error... 

 

 Error: List controllers are not supported for CampaignMember

 

 

All I want is a paginated list display of CampaignMember records...

 

In reality I would love an enhances list of CampaignMember records but I can't do that... Any ideas. 

 

I need to work with this object specifically.

 

update: <apex:listViews type="CampaignMember" /> works but won't suffice as I need to be able to specify what type of element is displayed in the list.

 

As it's an 'editable' grid like list I need to create.

Message Edited by pbulacz on 10-19-2009 05:45 PM

Hi All,

 

Getting quite frustrated with trying to find a solution for this issue.

 

Using Batch Apex and it is intermittently working correctly.

 

I have raised a case #03007660 ... however lucky me has had it assigned to someone out of office (that's the email reply I got anyway).

 

See my code below.

 

I have tried and tested it with batches of up to 327 records and it has worked successfully. However now trying to test with larger batches of >3000 records all I get is a debug log that says see below. And my Apex Jobs log just says..

 

Job Type = Batch Apex

Status = Completed

Total Batches = 0

Batches Processed = 0

Failures = 0

 

Essentially nothing happens. No error no real message nothing. Any help would be much appreciated here, I've seen a few other posts with similar issues, however this is getting critical for me to find a solution! 

 

I have also tried 'chunking' the batches at varying intervals all the way from 25 - 200 in the 'execute' method, without any success and also as another post suggested added a 'limit' to my query which also didn't help.

 

SOQL locator query with 3324 rows finished in 608 msCumulative resource usage:Total email recipients queued to be sent : 0Stack frame variables and sizes:  Frame0

 

global class PaymentCreate implements Database.Batchable<SObject>{// Creates and Processes Payments
public date PSBD;
public String PSID;
public String PSM;
Public String query;
global database.querylocator start(Database.BatchableContext BC){
  return Database.getQueryLocator(query);
}

global void execute(Database.BatchableContext BC, Sobject[] scope){
  List<AcctPayments__c> PaymentHolder = new List<AcctPayments__c>();
  List<Recurring_Payment__c> batchRP = new List<Recurring_Payment__c>();
  for(sobject s : scope){
    Recurring_Payment__c p = (Recurring_Payment__c)s;
    PaymentHolder.add(new AcctPayments__c(Payment_Session__c = PSID, Contact__c = p._Contact__c, Payment_Total__c = p.Recurring_Amount__c, Auto_Allocate__c = true, Payment_Method__c = PSM, RP_ID__c = p.Id, RP__c = p.Id, Recurring_Payment_Processed__c = true));
    p.MEMforce__Last_Processed__c = PSBD;
    batchRP.add(p);
  }
  insert PaymentHolder;
  update batchRP;
}

global void finish(Database.BatchableContext BC){
Messaging.SingleEmailMessage mail = new Messaging.SingleEmailMessage();
mail.setReplyTo('batch@batch.com.au');
mail.setTargetObjectId(UserInfo.getUserId());
mail.setSaveAsActivity(false);
mail.setSenderDisplayName('Batch Processing - Payments Updated (Loaded and Processed)');
mail.setSubject('Batch Process Completed - Payments Updated (Loaded and Processed)');
mail.setPlainTextBody('Batch Process has completed - Payment Updated (Loaded and Processed)');
Messaging.sendEmail(new Messaging.SingleEmailMessage[] { mail });
}
}
 //INVOKE
     loading.query= myQuery;     loading.PSID = thisPS.Id;
     loading.PSBD= thisPS.Banking_Date__c;
     loading.PSM = thisPS.Payment_Method__c;
     ID batchprocessid = Database.executeBatch(loading, 50);
Message Edited by Patrick Bulacz on 10-15-2009 09:36 PM

In Winter 10.

 

I have a batch apex that could potentially return at least  250000 records. 

 

Documentation says that batch jobs using a query locator can return 50 million records.

 

But, the batch job that I have does not work if the query returns even 20000 records.

 

Anyone with the same issue? 

  • October 01, 2009
  • Like
  • 0

I'm considering writing a batch cloning operation for opportunities.  I'm concerned that I'm going to bump up against governor limits, here's why:

 

I have quite a few triggers that fire on the creation of new opps.  They're all bulkified but I still run into heap size limits and occasionally SOQL rows when inserting (or updating) batches of opportunities greater than 40-50 through the API (DataLoader, DemandTools, etc.). 

 

As I understand it, batch apex won't let me work with batches smaller than 200, so my question is, will I run into the same heap size limits or SOQL rows in batch apex? When my DML is executed for my batch(es), and in turn fires triggers, are those triggers operating with trigger governor limits for this transaction, or within the higher batch apex governor limits?

Message Edited by DManelski on 08-26-2009 11:20 AM

I have a before insert / before update trigger on event that does some calculations and uses the StartDateTime and EndDateTime fields for it's processing.

 

Now all works fine for single events (i.e. 1 off events not part of a series).

 

However when I try and UPDATE an event that is part of a series the startdatetime and enddatetime appear wrong, and are ruining my results.

 

This only happens on UPDATE, for insert of a recurring series everything calculates fine, but when I just try and edit only one of the events in a series the startDateTime get skewed.

 

Any Ideas? Is it somehow based on system time vs the local time settings of the org or something like that?

 

My startdatetime SHOULD BE

START =2009-06-15 08:30:00  END =2009-06-16 17:30:00
But as you can see in the Debug log excerpt below the start and end times are completely skewed!!

20090611063904.439:Trigger.Event_Before_Update: line 55, column 9: INITIAL START =2009-06-15 22:30:00
20090611063904.439:Trigger.Event_Before_Update: line 56, column 9: INITIAL END =2009-06-16 07:30:00

 Debugging a single event that isn't part of a series doesn't shed much light either as the start and end time/date is STILL SKEWED however for some reason the code processes it fine???

 

This ones a bit confusing any help would be great.

 

 

Message Edited by pbulacz on 06-10-2009 11:58 PM
Message Edited by pbulacz on 06-11-2009 04:12 PM
Message Edited by pbulacz on 06-11-2009 04:13 PM

I'm doing a RunAllTests and am getting the following:

Exception in Account_AsynchProcessing TriggerFuture method cannot be called from a future method: formatSObjectData(String, LIST:String)

 

I'm not sure what the Exception is saying.  Here is the setup:

-  A trigger has a statement that calls a @future method in a global class.  The future method itself does not make calls to other future methods.

 

Is it invalid to call @future methods from a trigger?

 

Thanks.