• adam_purkiss
  • NEWBIE
  • 10 Points
  • Member since 2010

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

I've thought of everything I can here but just can't understand why this is happening.  This AppExchange ackage is certified - passed the security review.  Here's the trigger code that continues to error out with too much DML/SQL queries.  Any help would be greatly appreciated!

 

 

trigger LHQUpdateCampaignMembers on CampaignMember (before insert, before update, before delete) 
{
	if((Trigger.isBefore && Trigger.isInsert) || (Trigger.isBefore && Trigger.isUpdate))
	{
		List<String> conIds = new List<String>();
		List<String> ledIds = new List<String>();
		List<String> camIds = new List<String>();

		for(CampaignMember c : Trigger.new)
		{
			conIds.add(c.ContactId);
			ledIds.add(c.LeadId);
			camIds.add(c.CampaignId);
		}
	
		Contact[] conList = [SELECT Id, LHQUpdateContactBit__c FROM Contact WHERE Id IN :conIds];
		Lead[] ledList = [SELECT Id, LHQUpdateLeadBit__c, IsConverted FROM Lead WHERE Id IN :ledIds];
		Campaign[] camList = [SELECT Id, LHQUpdateCampaignBit__c FROM Campaign WHERE Id IN :camIds];
	
		for(Contact c : conList)
		{
			c.LHQUpdateContactBit__c = false;
		}

		// Prepare Lead list without converted leads
		List<Lead> ledList2 = new List<Lead>();
			
		for(Lead l : ledList)
		{
			if(!l.IsConverted)
			{
				Lead ll = l;
				ledList2.add(ll);
			}
		}

		for(Lead l : ledList2)
		{
			l.LHQUpdateLeadBit__c = false;
		}
			
		for(Campaign c : camList)
		{
			c.LHQUpdateCampaignBit__c = false;
		}
			
		update conList;
		update ledList2;
		update camList;
	}
}

 

 

While trying to browse data in FeedComment, FeedPost and FeedTrackedChange via SELECT from Eclipse I get the following error:

 

 

Anyone have the same experience?  I'm thinking it's me at this point and not a bug.

 

Thanks!

Adam

fellow developers,

here is a custom search engine built for you , please test drive and let me know your feedback via feedback button on the site.

www.cloudgofer.com , also feel free to send in request to add more salesforce specific sites to the custom search engine.

 

No more going through different manuals or guides to lookup a syntax for tag or an API.

All:

 

Been searching all day for help, new to APEX triggers, and need to know if anyone can help:

 

I have two customer objects that I am using. I need to run a lookup to pull a field value from one custom object to another.

 

I have the field "Customer Name"  in Household Addresses. I need the value from "Customer Name"  to appear in the "Household Name" field of custom object GPON Addresses, if a certain criteria is met (if the address field is a match). I have tried a VLOOKUP but since the obejcts are not related in the API I cannot get it to work. Please let me know if more detail is needed.

 

Matthew Hampton

When using the vote component on a VF page, I'm getting an error that $StandardLabel.voteButton.promote is not defined.  Anyone know why this wouldn't be defined, since it's a StandardLabel and how to fix it?

  • September 23, 2010
  • Like
  • 0

Hi

 

I am using eclipse to write a new apex trigger.

 

 

 

and I am getting the attached error message. Any help would be great.

 

I am getting error message. An expected error has occurred.

trigger RequestLineItem_AfterInsert on Request_Line_Item__c (after insert) {
	for(Request_Line_Item__c reqli: trigger.new){
		List<Product_Group__c> pg = [Select p.id, p.Technical_Owner__c, p.Business_Owner__c From Product_Group__c p where Product_Group__c =
										:reqli.Product_Group__c LIMIT 1];
	
		//reqli.Product_Group_Object__c = pg.get(0).id;
		update reqli;
		
	
	}
}

 

 

  • May 27, 2010
  • Like
  • 0

Running all tests in Salesforce shows 91% test coverage, yet the package upload wizard says only 52% and fails to package.

 

Not a single class falls under 78%.... most are 100%.

 

What would cause this?

 

 

 

 

Thanks

 

-Mike

 

 

I've thought of everything I can here but just can't understand why this is happening.  This AppExchange ackage is certified - passed the security review.  Here's the trigger code that continues to error out with too much DML/SQL queries.  Any help would be greatly appreciated!

 

 

trigger LHQUpdateCampaignMembers on CampaignMember (before insert, before update, before delete) 
{
	if((Trigger.isBefore && Trigger.isInsert) || (Trigger.isBefore && Trigger.isUpdate))
	{
		List<String> conIds = new List<String>();
		List<String> ledIds = new List<String>();
		List<String> camIds = new List<String>();

		for(CampaignMember c : Trigger.new)
		{
			conIds.add(c.ContactId);
			ledIds.add(c.LeadId);
			camIds.add(c.CampaignId);
		}
	
		Contact[] conList = [SELECT Id, LHQUpdateContactBit__c FROM Contact WHERE Id IN :conIds];
		Lead[] ledList = [SELECT Id, LHQUpdateLeadBit__c, IsConverted FROM Lead WHERE Id IN :ledIds];
		Campaign[] camList = [SELECT Id, LHQUpdateCampaignBit__c FROM Campaign WHERE Id IN :camIds];
	
		for(Contact c : conList)
		{
			c.LHQUpdateContactBit__c = false;
		}

		// Prepare Lead list without converted leads
		List<Lead> ledList2 = new List<Lead>();
			
		for(Lead l : ledList)
		{
			if(!l.IsConverted)
			{
				Lead ll = l;
				ledList2.add(ll);
			}
		}

		for(Lead l : ledList2)
		{
			l.LHQUpdateLeadBit__c = false;
		}
			
		for(Campaign c : camList)
		{
			c.LHQUpdateCampaignBit__c = false;
		}
			
		update conList;
		update ledList2;
		update camList;
	}
}

 

 

While trying to browse data in FeedComment, FeedPost and FeedTrackedChange via SELECT from Eclipse I get the following error:

 

 

Anyone have the same experience?  I'm thinking it's me at this point and not a bug.

 

Thanks!

Adam

Do we have a limit of one thousand records that can be processed per DML statement? I believe, that was to do with the earler collection limit of one thousand records. Since, there is no limit on number of records in the collection, do we still have a limit on the number of records processed per DML statement. Please advice.

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

Does anybody know how to use the Apex:vote component?

I'm 99% to a page with a decent layout for internal users.  This is probably trivial, but for whatever reason, I can't find it.  We only have one community, and it seems really stupid to force people to choose the community when they are creating an idea.

 

How do I 'hard code' the communityid in the VF page.

 

Here is my code that works, if I search and then select, my one community:

 

<apex:page standardController="idea">

<apex:form >

<apex:pageBlock title="New Idea">

<apex:pageBlockButtons >

<apex:commandButton action="{!save}" value="Save"/>

</apex:pageBlockButtons>

<apex:pageBlockSection title="Idea Details" columns="1">

<apex:inputField style="width:250px" value="{!idea.title}"/>

<apex:inputField required="true" value="{!idea.CommunityId}"/>

<apex:inputField required="true" value="{!idea.category}"/>

<apex:inputField required="true" value="{!idea.Requested_Priority__c}"/> <apex:inputField required="true" style="width:600px" value="{!idea.Business_Case__c}"/>

<apex:inputField required="true" style="width:600px" value="{!idea.body}"/>

</apex:pageBlockSection>

</apex:pageBlock>

</apex:form>

</apex:page>

 

 I've tried various tags, but there should be some way to just say that {!idea.communityid} = <id>

 

Also, I hope the answer isn't that I have to write a controller extension JUST to hard code this value... 

Message Edited by BarryPlum on 12-22-2009 09:37 AM
Hi,
 
I am trying to insert a new entry in my database with the insert call. but I always get the 

DML currently not allowed

message.

I just fill the customer object fields and call insert like following:

Custom__c custom=new Custom__c();

custom.name='blabla';

custom.value='blabla';

insert custom;

Does anyone knows how to solve this problem. Thanks in advance.

 

bye

 

 

  • January 03, 2008
  • Like
  • 0