• kiwitrotter
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 8
    Questions
  • 7
    Replies
Hi all,

Just a quick question to see if anyone has come across this already. In one of our Sandboxes I have the pre-release of Spring 15 (our live instance is on Winter 15) and when I try to run a query using the LIKE comparison operator it won't let me run the query.

For example, a very simple query as follows to pull back a list of users containing 'Power' as part of their full name:

Select Email From User Where Name Like '%Power%'

This query will not execute on Spring 15 but it runs fine and returns the expected results when I run it on our live instance. I performed the queries in both instances via the Developer Console.

Any thoughts on this would be most welcome as I'm concerned that the upcoming release that is due to be implemented in our live instance next month will have the same problem. We don't have developer support as part of our Salesforce contract which is why I am posting this issue here.

Many thanks in advance for your help with this.

Hi guys,

 

I'm wondering if anyone can help me out on this one.

 

I have a Visualforce page that displays different fieldsets of checkbox fields. This Visualforce page is embedded in one of our custom object layouts and up until the release of Summer '13 the inline editing functionality was working whereby when we went to view a record we were able to double click the checkboxes displayed by this Visualforce page and save these changes without having to go into the full edit mode of the record itself.

 

My investigations on this so far have revealed in my Sandbox that if I bring up this Visualforce page standalone (outside of the object layout that it's embedded in) this functionality works, but when I view a record that this visual force page is embedded into the inline editing will not work. The only option is to go into the full edit mode of the record itself.

 

Has anyone had a similiar experience or can you suggest any solutions to this problem? Like I said earlier this functionality was working fine up until the release of Summer '13.

 

Many thanks in advance for your help.

 

 

Hi guys,

 

My question is more related to SOQL querying via a query editor rather than using SOQL in Apex.

 

Below is my query and when I run this query through a query editor such as Force.com explore or Real Force Explore the result set that comes back displays the record count for the sub query which you have to click on in order to see the actual records returned.

 

SELECT SFSSDupeCatcher__Duplicate_Warning_Count__c, Name, SFSSDupeCatcher__Scenario_Rule_Count__c, SFSSDupeCatcher__Scenario_Type__c, SFSSDupeCatcher__Potential_Duplicate_Count__c, (Select Name From SFSSDupeCatcher__Scenario_Rules__r) FROM SFSSDupeCatcher__Scenario__c

 

Is there any way to display a Parent-Child's sub query results also in the query results that are returned? I need to be able to export all results to a .csv file.

 

Thanks in advance for any help that you can give me with this.

Hi there,

 

I have added a custom console component to our Service Cloud console but what I'm trying to do is that when I click on the button to launch the component, I want to run a method in my controller that my visualforce page is calling. This component is made up of page that provides a quick view into our support team's cases queue, and a controller with methods that rerun the query to get a realtime view of the cases in the queue.

 

My question is, how do I get at the onclick event for this button? I have searched around for answers but so far I have been unable to find any. My goal is to use this console component as a quick view into our support teams cases queue so that wherever they are in the console (in a case, contact, organisation record, etc..) when they click on this component it will automatically refresh the view of the support cases that I'm displaying in this component.

 

So far I have only been able to get as far as adding some output text to my page and firing this refresh using the onlclick and onmouseover event. This isn't ideal for our team's requirements so ideally when they click on this component I would like to be able to fire the refresh then?

 

Any ideas on this please?

 

All help is greatly appreciated as always!

 

Thanks so much in advance to anyone taking the time to read this and offer assistance.

 

Kindest Regards,

 

Brian.

Hi there,

 

I'm wondering if anyone can help me out. I'm very new to Visual Workflow so forgive me if my question is very trivial. I have been looking up user guides and discussion boards but I cannot find the answer that I'm looking for.

 

My Problem:

----------------

I have a Radio Buttons Choice field type on my Visual Workflow screen, along with other fields such as textbox. I am using a Record Update to update some fields on my opportunity with the values inputted by the user in the screen on my workflow.

 

For some reason the only value that gets updated/saved in the opportunity is the textbox value. I cannot figure out how to get the Dropdown list choice selected by the user to update the associated field on the opportunity. Is there something obvious that I'm missing?

 

I am using the same assignment method for thedropdown list fields as I am for the textbox field, e.g.

 

Opp Field: Text_Field__c --> Value: {!Screen_Input_Textbox_field_value}

Opp Field: Picklist_Field__c --> Value: {!Screen_Input_Dropdown_List_Choice_Field_Value}

 

Any help on this is much appreciated!

 

Thank you very much!

 

Hi guys,

 

Just wondering if anyone can help me out with this one. I'm trying to query back the family value of an opportunity product line item so that I can populate a custom field with a value based on the product family that it belongs to. I have tried a few different things but nothing has worked. The closest that I can get is as follows:

 

---

trigger oppLineItemCheck on OpportunityLineItem (after insert) {

    for (OpportunityLineItem oli : Trigger.new)
    {
        String resultName = oli.PricebookEntry.Product2.Name;
        String resultFamily = oli.PricebookEntry.Product2.Family;
        Double lineItemPrice = oli.ListPrice;
        
        
        List <Opportunity> oList = [select name, amount from Opportunity where Id = :oli.OpportunityId];
        System.debug('Inside first for loop...');
        
        for (Opportunity o:oList){
            o.Description = 'Opportunity Product Name is: ' + resultName + ' Opportunity Product family is: ' + resultFamily;
           

            System.debug(o.Description); //prints null values to logs for name and family
            System.debug('Inside second for loop...');
            System.debug('Pricebook2Idb 1 = ' +oli.PriceBookEntryID); //prints PricebookEntryID value to logs
            System.debug('Pricebook2Idb 2 = ' +oli.PriceBookEntry.ID); //prints null
            

            if(resultFamily == 'Products'){
                o.Products_Amount__c = lineItemPrice;
            } else {
                o.Services_Amount__c = lineItemPrice;
            }
        }
    }
}

---

 

However, in my debug logs the values of the Product name and family are null. I'm probably missing something obvious here but if anyone can shed any light on this I would appreciate it.

 

Many thanks in advance.

Hi,

 

Just wondering if anyone can help me. I'm trying to validate the email address field of a lead in my before insert trigger. In my test class I'm simply providing a url as the email address of the test lead and trying to insert it. Thisi s then causing the following validation error to appear in the logs:

 

---

10:23:53.268 (13268597000)|DML_BEGIN|[33]|Op:Insert|Type:Lead|Rows:1
10:23:53.270 (13270063000)|DML_END|[33]
10:23:53.270 (13270191000)|VF_PAGE_MESSAGE|Email: invalid email address: http://www.dodgycompany.com
10:23:53.270 (13270274000)|EXCEPTION_THROWN|[33]|System.DmlException: Insert failed. First exception on row 0; first error: INVALID_EMAIL_ADDRESS, Email: invalid email address: http://www.dodgycompany.com: [Email]
10:23:53.272 (13272426000)|USER_DEBUG|[36]|DEBUG|Email: invalid email address: http://www.dodgycompany.com
10:23:53.272 (13272706000)|EXCEPTION_THROWN|[37]|System.ListException: List index out of bounds: 1
10:23:53.272 (13272884000)|FATAL_ERROR|System.ListException: List index out of bounds: 1

Class.TestDeDupeLead.testForValidEmailAddress: line 37, column 1
10:23:53.272 (13272898000)|FATAL_ERROR|System.ListException: List index out of bounds: 1
------

 

I don't understand why my attempt to insert a test lead with an invalid email address is failing. In my before insert trigger I have code in place to validate the lead's email address. I thought that my before trigger should run before any salesforce field validation takes place however it appears some kind of other field validation is happening before my 'before insert' trigger.

 

Can anyone shed any light on this? Your help is greatly appreciated!

 

Many thanks in advance!

Hi all,

 

I am new to this discussion board and I realise that this may have been posted a few times before but I have been unable to find a definitive resolution to this problem whereby it doesn't seem to be possible to get a list of picklist values relative to the record type.

 

My scenario is that we have a lead status picklist field that displays certain statuses if the record type is a Sales Record Type and displays a different set of statuses if the record type is a Marketing Record type. The following code that I use to try and pull out the lead statuses relavent to a particular record type doesn't work and instead the complete list of lead status values for both Sales and Marketing leads is displayed instead:

 

public List<SelectOption> getLeadStatusValue(){
    if(leadStatusValue == null){
        
        Schema.DescribeFieldResult fieldResult = Lead.Status.getDescribe();
        List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
        List<SelectOption> options = new List<SelectOption>();
        options.add(new SelectOption('', ''));
                     
        for( Schema.PicklistEntry f : ple)
        {
            options.add(new SelectOption(f.getLabel(), f.getValue()));
        }       
        leadStatusValue = options;
    }
    return leadStatusValue;
}

 

Does anybody know of any solution to this problem? Any help is greatly appreciated.

 

Thanks a million!

Hi guys,

 

I'm wondering if anyone can help me out on this one.

 

I have a Visualforce page that displays different fieldsets of checkbox fields. This Visualforce page is embedded in one of our custom object layouts and up until the release of Summer '13 the inline editing functionality was working whereby when we went to view a record we were able to double click the checkboxes displayed by this Visualforce page and save these changes without having to go into the full edit mode of the record itself.

 

My investigations on this so far have revealed in my Sandbox that if I bring up this Visualforce page standalone (outside of the object layout that it's embedded in) this functionality works, but when I view a record that this visual force page is embedded into the inline editing will not work. The only option is to go into the full edit mode of the record itself.

 

Has anyone had a similiar experience or can you suggest any solutions to this problem? Like I said earlier this functionality was working fine up until the release of Summer '13.

 

Many thanks in advance for your help.

 

 

Hi guys,

 

My question is more related to SOQL querying via a query editor rather than using SOQL in Apex.

 

Below is my query and when I run this query through a query editor such as Force.com explore or Real Force Explore the result set that comes back displays the record count for the sub query which you have to click on in order to see the actual records returned.

 

SELECT SFSSDupeCatcher__Duplicate_Warning_Count__c, Name, SFSSDupeCatcher__Scenario_Rule_Count__c, SFSSDupeCatcher__Scenario_Type__c, SFSSDupeCatcher__Potential_Duplicate_Count__c, (Select Name From SFSSDupeCatcher__Scenario_Rules__r) FROM SFSSDupeCatcher__Scenario__c

 

Is there any way to display a Parent-Child's sub query results also in the query results that are returned? I need to be able to export all results to a .csv file.

 

Thanks in advance for any help that you can give me with this.

Hi guys,

 

Just wondering if anyone can help me out with this one. I'm trying to query back the family value of an opportunity product line item so that I can populate a custom field with a value based on the product family that it belongs to. I have tried a few different things but nothing has worked. The closest that I can get is as follows:

 

---

trigger oppLineItemCheck on OpportunityLineItem (after insert) {

    for (OpportunityLineItem oli : Trigger.new)
    {
        String resultName = oli.PricebookEntry.Product2.Name;
        String resultFamily = oli.PricebookEntry.Product2.Family;
        Double lineItemPrice = oli.ListPrice;
        
        
        List <Opportunity> oList = [select name, amount from Opportunity where Id = :oli.OpportunityId];
        System.debug('Inside first for loop...');
        
        for (Opportunity o:oList){
            o.Description = 'Opportunity Product Name is: ' + resultName + ' Opportunity Product family is: ' + resultFamily;
           

            System.debug(o.Description); //prints null values to logs for name and family
            System.debug('Inside second for loop...');
            System.debug('Pricebook2Idb 1 = ' +oli.PriceBookEntryID); //prints PricebookEntryID value to logs
            System.debug('Pricebook2Idb 2 = ' +oli.PriceBookEntry.ID); //prints null
            

            if(resultFamily == 'Products'){
                o.Products_Amount__c = lineItemPrice;
            } else {
                o.Services_Amount__c = lineItemPrice;
            }
        }
    }
}

---

 

However, in my debug logs the values of the Product name and family are null. I'm probably missing something obvious here but if anyone can shed any light on this I would appreciate it.

 

Many thanks in advance.

Hi,

 

Just wondering if anyone can help me. I'm trying to validate the email address field of a lead in my before insert trigger. In my test class I'm simply providing a url as the email address of the test lead and trying to insert it. Thisi s then causing the following validation error to appear in the logs:

 

---

10:23:53.268 (13268597000)|DML_BEGIN|[33]|Op:Insert|Type:Lead|Rows:1
10:23:53.270 (13270063000)|DML_END|[33]
10:23:53.270 (13270191000)|VF_PAGE_MESSAGE|Email: invalid email address: http://www.dodgycompany.com
10:23:53.270 (13270274000)|EXCEPTION_THROWN|[33]|System.DmlException: Insert failed. First exception on row 0; first error: INVALID_EMAIL_ADDRESS, Email: invalid email address: http://www.dodgycompany.com: [Email]
10:23:53.272 (13272426000)|USER_DEBUG|[36]|DEBUG|Email: invalid email address: http://www.dodgycompany.com
10:23:53.272 (13272706000)|EXCEPTION_THROWN|[37]|System.ListException: List index out of bounds: 1
10:23:53.272 (13272884000)|FATAL_ERROR|System.ListException: List index out of bounds: 1

Class.TestDeDupeLead.testForValidEmailAddress: line 37, column 1
10:23:53.272 (13272898000)|FATAL_ERROR|System.ListException: List index out of bounds: 1
------

 

I don't understand why my attempt to insert a test lead with an invalid email address is failing. In my before insert trigger I have code in place to validate the lead's email address. I thought that my before trigger should run before any salesforce field validation takes place however it appears some kind of other field validation is happening before my 'before insert' trigger.

 

Can anyone shed any light on this? Your help is greatly appreciated!

 

Many thanks in advance!