• David Fry
  • NEWBIE
  • 15 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 3
    Replies
I'm working with list of lists and there is a syntax I'm seeing that I'm not familiar with.  Can someone clarify what this is doing?
 
List<List<sObject>> myListOfLists = New List<List<sObject>>();
myListOfLists = [SOME SOSL QUERY];

List<myObject> oneList = New List<myObject>();

oneList = ((List<myObject>)myListOfLists[0]);
The section in bold is what I don't understand is happening?  Can someone explain?   It almost looks like it's casting the first list as my new list type but I'm not sure.
Thanks for the help.
 
Hello, hopefully some of you have some experience with this.  We are currently deploying the Duplicate Management and when the rules are deployed in "Alert" mode (not blocking), the VF page still shows an error and whether or not the record is inserted seems a bit random.  (We've not researched that part yet).

My question is this... does anyone know if it's possible to differentiate a Duplicate Management Alert from an Error via APEX?   If we could know what it is, we could code accordingly.

Thanks
Hello All, I come from a SQL data background and I'm trying to build a very simple aggregate query joining to related objects.  No matter what I do, I get an error. Is there any way to build this simple query?  This is not to be implemented within APEX code, so doing it in pieces or using variables isn't an option.  I need a direct query as this is for use in organizing and improving some of our internal data collection and integration tools.

Here are the details:
Parent Object: Trunk_Group__c
Child Related Object: Trunk_Telephone_Lines__c

Here are the attempts I have made to no avail (I've tried other variations as well but no go):

SELECT Lead_TN__c, (Select Count(Id) From Trunk_Telephone_Lines__r ) FROM Trunk_Group__c Where Related_Trunk_Service_Request__c = 'big_long_sfdc_id' Group By Lead_TN__c


SELECT Trunk_Group__r.Lead_TN__c, Count(Id) FROM Trunk_Telephone_Lines__c Where  Trunk_Group__r.Related_Trunk_Service_Request__c  = 'big_long_sfdc_id'
Group By Trunk_Group__r.Lead_TN__c
I'm working with list of lists and there is a syntax I'm seeing that I'm not familiar with.  Can someone clarify what this is doing?
 
List<List<sObject>> myListOfLists = New List<List<sObject>>();
myListOfLists = [SOME SOSL QUERY];

List<myObject> oneList = New List<myObject>();

oneList = ((List<myObject>)myListOfLists[0]);
The section in bold is what I don't understand is happening?  Can someone explain?   It almost looks like it's casting the first list as my new list type but I'm not sure.
Thanks for the help.
 
Hello, hopefully some of you have some experience with this.  We are currently deploying the Duplicate Management and when the rules are deployed in "Alert" mode (not blocking), the VF page still shows an error and whether or not the record is inserted seems a bit random.  (We've not researched that part yet).

My question is this... does anyone know if it's possible to differentiate a Duplicate Management Alert from an Error via APEX?   If we could know what it is, we could code accordingly.

Thanks
Hello All, I come from a SQL data background and I'm trying to build a very simple aggregate query joining to related objects.  No matter what I do, I get an error. Is there any way to build this simple query?  This is not to be implemented within APEX code, so doing it in pieces or using variables isn't an option.  I need a direct query as this is for use in organizing and improving some of our internal data collection and integration tools.

Here are the details:
Parent Object: Trunk_Group__c
Child Related Object: Trunk_Telephone_Lines__c

Here are the attempts I have made to no avail (I've tried other variations as well but no go):

SELECT Lead_TN__c, (Select Count(Id) From Trunk_Telephone_Lines__r ) FROM Trunk_Group__c Where Related_Trunk_Service_Request__c = 'big_long_sfdc_id' Group By Lead_TN__c


SELECT Trunk_Group__r.Lead_TN__c, Count(Id) FROM Trunk_Telephone_Lines__c Where  Trunk_Group__r.Related_Trunk_Service_Request__c  = 'big_long_sfdc_id'
Group By Trunk_Group__r.Lead_TN__c