• Michael Coluzzi
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 0
    Replies
Hello Everyone,

We are currently running into an issue where the queries in one of our visualforce pages is taking a very long time to execute. Currently the query is taking around 120 seconds sometimes more to return thier results. Adding a "where condition" has descreased the time but I am looking to see if anyone has any possible suggestions to improve it further. I have posted both queries(with and without WHERE condition). Let me know if you need any further information.

Thank you!

Without Where Condition:

SELECT id, Name, type, owner.Name, website FROM Account ORDER BY LastModifiedDate DESC LIMIT 50

SELECT id, FirstName, Name, LastName, Email, Account.Name, Department, Title, Phone FROM Contact ORDER BY LastModifiedDate DESC LIMIT 50

SELECT id, Account.Name, AccountId, Name, Type, Amount, StageName, Probability, owner.Name, CloseDate FROM Opportunity ORDER BY LastModifiedDate DESC LIMIT 50

Select Username, Title, TimeZoneSidKey, ProfileId, Phone, Name, LastName, Id, FirstName, Email, Division, Department From User WHERE IsActive = true ORDER BY LastModifiedDate DESC LIMIT 50

With Where Condition:

SELECT id, Name, type, owner.Name, website FROM Account where lastvieweddate = LAST_N_DAYS:30 ORDER BY LastViewedDate DESC NULLS LAST LIMIT 50


SELECT id, FirstName, Name, LastName, Email, Account.Name, Department, Title, Phone FROM Contact where lastvieweddate = LAST_N_DAYS:30 ORDER BY LastViewedDate DESC NULLS LAST LIMIT 50

SELECT id, Account.Name, AccountId, Name, Type, Amount, StageName, Probability, owner.Name, CloseDate FROM Opportunity where lastvieweddate = LAST_N_DAYS:30 ORDER BY LastViewedDate DESC NULLS LAST LIMIT 50

Select Username, Title, TimeZoneSidKey, ProfileId, Phone, Name, LastName, Id, FirstName, Email, Division, Department From User WHERE IsActive = true AND lastvieweddate = LAST_N_DAYS:30 ORDER BY LastViewedDate DESC NULLS LAST LIMIT 50


 

Hi All!

I was attempting the "Build Flexible Apps with Visualforce Pages and Lightning Components" trailhead project but I am unable to install the package that the require to be installed prior to beginning. When i go to install the package, I recieve the errors below. I verified that it is installing into my "Hands-On Org" and I even attempted creating a new Trailhead org and the same issues persists. 

Method does not exist or incorrect signature: void setCurrentPage(System.PageReference) from the type test
DreamhouseTests: Method does not exist or incorrect signature: void setCurrentPage(System.PageReference) from the type test

Method does not exist or incorrect signature: void isRunningTest() from the type test
GetPropertiesApexController: Method does not exist or incorrect signature: void isRunningTest() from the type test

Apex class 'GetPropertiesApexController' does not exist
Similar_Properties: Apex class 'GetPropertiesApexController' does not exist


Does anyone have any ideas what I might have to do to fix this. Sorry if there has been an answer posted already, I couldn't seem to find one.

Thank you,

Michael