• Patrick Bulacz
  • NEWBIE
  • 30 Points
  • Member since 2008

  • Chatter
    Feed
  • 1
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 9
    Replies

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

Hi All,

 

I work with an ISV Partner who has a developer org where a managed package is updated / upgraded / tested and then uploaded "privately' to the exchange for a set of clients to install.

 

The orgs that install my package have the standard EE limits applied to them.

 

Herein lies the issue I have come across, whilst doing some development a new TAB was inadvertently added to the managed package and subsequently uploaded as a 'managed - released' package. It took the custom TABS within the managed package to 26.

 

This as you can see has caused HUGE implications across the current install base and for new clients. The package is constantly being updated / customised to suit clients needs and updates are continously being pushed however now that it has 26 TABS it will not install on any of the orgs as it reaches the 25 custom tab limit.

 

I REALLY NEED HELP BRAINSTORMING SOME POSSIBLE SOLUTIONS!!!

 

As I see it there are a range of possibilities and I look to any sf reps / partner ops / product managers subject matter experts out there to let me know what is feasible.

 

IDEAL SOLUTION - Since the tab that has been added is not installed on any clients org (it physically cannot be because of the limit on the install orgs, developer org doesn't have a tab limit) - I'm looking for an overall package admin or someone that can reference or edit the package I have created and manually remove the tab from it altogether. It can be deleted from the salesforce developer instance altogether I don't care it's not needed at all! Support tells me it cannot be deleted but someone out there must have access to it!!

Is there a way to 'rollback' to a previous package version that only had 25tabs in it's managed set>? And then be able to delete the 25th tab somehow completely from the developer org?

 

Other options include:

 

Going through the LMA process and getting the application security checked so that it's contents do not affect sf org limits. This is obviously primary concern right now however the whole process could take up to 2-3 weeks which is time we don't have! This problem needed to be sorted out YESTERDAY!

 

Upgrading provisions on future clients and current installbase so that orgs can install apps with more than 25 tabs. (i.e. increase tab limit)

 

I really need to know if the ideal solution is feasible here as that would be well... Ideal. But I'm interested to see if anyone has any other suggestions.

TIME IS A FACTOR. There are new clients coming on board this week and next not to mention the current install base that is catered for in package updates so this really needs to get sorted out.

 

As always any help is much appreciated. Thanks in advance for any reads of this post.

 

Patrick

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

Hi All,

 

Just wondering if anyone has had any experience with working around the 100000 char limit on Strings in Apex.

 

Basically am producing a large text file that needs to then be attached to a record via notes and attachments.

 

I've got a few workarounds but wondering if there are any other ideas out there.

 

Ideally I'd like to check the length of the string and if it's 'nearing' the limit convert it to a blob and add it to a list of blobs and then run a loop and add all the blobs together to create 1 large file and then attach that via notes and attachments. Obviously that can't be done because you can't just simply add blobs but that's the basic dilemma so if anyone has any suggestions please let me know.

 

My other solutions are to generate the output to a visualforce page then scrape the visualforce page but I get the ugly <Html> and </Html> tags at the beginning and the formatting is a little off (would be good to just be able to 'renderAs=text' but oh well.

 

Anyway any help is much appreciated.

 

Cheers,

 

Patrick

Hi all,

Just wondering if I can use the Excel Connector for an EE Instance to import Person Accounts.

Or otherwise how does one go about importing Person Accounts? Is it a matter of importing accounts and contacts seperately and then 'flicking the record type switch' ?

I have a brand new instance with all contacts needing to be entered in as person accounts.

Any help would be great. Thanks

Hi All,

 

Just wondering if anyone has had any experience with working around the 100000 char limit on Strings in Apex.

 

Basically am producing a large text file that needs to then be attached to a record via notes and attachments.

 

I've got a few workarounds but wondering if there are any other ideas out there.

 

Ideally I'd like to check the length of the string and if it's 'nearing' the limit convert it to a blob and add it to a list of blobs and then run a loop and add all the blobs together to create 1 large file and then attach that via notes and attachments. Obviously that can't be done because you can't just simply add blobs but that's the basic dilemma so if anyone has any suggestions please let me know.

 

My other solutions are to generate the output to a visualforce page then scrape the visualforce page but I get the ugly <Html> and </Html> tags at the beginning and the formatting is a little off (would be good to just be able to 'renderAs=text' but oh well.

 

Anyway any help is much appreciated.

 

Cheers,

 

Patrick

Hi All,

 

I work with an ISV Partner who has a developer org where a managed package is updated / upgraded / tested and then uploaded "privately' to the exchange for a set of clients to install.

 

The orgs that install my package have the standard EE limits applied to them.

 

Herein lies the issue I have come across, whilst doing some development a new TAB was inadvertently added to the managed package and subsequently uploaded as a 'managed - released' package. It took the custom TABS within the managed package to 26.

 

This as you can see has caused HUGE implications across the current install base and for new clients. The package is constantly being updated / customised to suit clients needs and updates are continously being pushed however now that it has 26 TABS it will not install on any of the orgs as it reaches the 25 custom tab limit.

 

I REALLY NEED HELP BRAINSTORMING SOME POSSIBLE SOLUTIONS!!!

 

As I see it there are a range of possibilities and I look to any sf reps / partner ops / product managers subject matter experts out there to let me know what is feasible.

 

IDEAL SOLUTION - Since the tab that has been added is not installed on any clients org (it physically cannot be because of the limit on the install orgs, developer org doesn't have a tab limit) - I'm looking for an overall package admin or someone that can reference or edit the package I have created and manually remove the tab from it altogether. It can be deleted from the salesforce developer instance altogether I don't care it's not needed at all! Support tells me it cannot be deleted but someone out there must have access to it!!

Is there a way to 'rollback' to a previous package version that only had 25tabs in it's managed set>? And then be able to delete the 25th tab somehow completely from the developer org?

 

Other options include:

 

Going through the LMA process and getting the application security checked so that it's contents do not affect sf org limits. This is obviously primary concern right now however the whole process could take up to 2-3 weeks which is time we don't have! This problem needed to be sorted out YESTERDAY!

 

Upgrading provisions on future clients and current installbase so that orgs can install apps with more than 25 tabs. (i.e. increase tab limit)

 

I really need to know if the ideal solution is feasible here as that would be well... Ideal. But I'm interested to see if anyone has any other suggestions.

TIME IS A FACTOR. There are new clients coming on board this week and next not to mention the current install base that is catered for in package updates so this really needs to get sorted out.

 

As always any help is much appreciated. Thanks in advance for any reads of this post.

 

Patrick

I included some custom tab definitions in a managed-released package. Those tabs are no longer necessary and I want to remove them from future versions of the package.

Could any one enlighten me on how to do this?

I can make this tab hidden from all profiles - but is there a way to clean up the package definition? 

 

Thanks for your help.  

  • October 27, 2009
  • Like
  • 0

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 getting the following error with IE in the Salesforce javascript supporting Ajax calls ....

 

 

Webpage error details User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0) Timestamp: Wed, 23 Sep 2009 02:00:43 UTC Message: Unknown runtime error Line: 120 Char: 1 Code: 0 URI: http://homewarrantygroup.force.com/faces/a4j/g/3_3_0.GAorg.ajax4jsf.javascript.AjaxScript

 



 

 

The page is hosted in an iFrame and works perfectly in Firefox, but when I click an actionButton in IE, the Ajax callback starts (but doesn't finish) and IE shows this error in the alerts area.

 

Has anyone else run into this error?  Is there a fix?

 

Thanks,

Ron 

Hi All,

 

Just wondering if anyone has had any experience with working around the 100000 char limit on Strings in Apex.

 

Basically am producing a large text file that needs to then be attached to a record via notes and attachments.

 

I've got a few workarounds but wondering if there are any other ideas out there.

 

Ideally I'd like to check the length of the string and if it's 'nearing' the limit convert it to a blob and add it to a list of blobs and then run a loop and add all the blobs together to create 1 large file and then attach that via notes and attachments. Obviously that can't be done because you can't just simply add blobs but that's the basic dilemma so if anyone has any suggestions please let me know.

 

My other solutions are to generate the output to a visualforce page then scrape the visualforce page but I get the ugly <Html> and </Html> tags at the beginning and the formatting is a little off (would be good to just be able to 'renderAs=text' but oh well.

 

Anyway any help is much appreciated.

 

Cheers,

 

Patrick

Hi All,


I'm the Product Manager for packaging here at salesforce.com.  We're currently working on a feature that would allow fields and objects to be removed from managed packages.  This is a popular request and something we're hoping to deliver very soon, but we need your help.  Please respond to this post with any thoughts around this topic.  I've included a few questions to get the conversation going:


  • Why do you want to remove these?  No longer used?  Customers didn't like them?  Replace with a new field?
  • When you deprecate a field/object, what should happen for existing customers?  New customers?
  • Would you have to remove all usage of a field/object in your app before you can deprecate it?  What happens if you've included the field in another formula field, etc?  
Thanks for your time and input!
Message Edited by A_Smith on 02-20-2009 05:55 PM