• santhos
  • NEWBIE
  • 0 Points
  • Member since 2011

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

I am trying to populate a record with the visual force page Url with the custom controller. I am using get parameters in my controller. When I pass values to the url, after some time it is giving me the below error.

 

Time limit exceeded

Your request exceeded the time limit for processing.

 

Our organization has around 1 million records.

 

This is the query i am using in my controller to search for that particular record.

 

LeadNumList = [Select id,name from lead where lead_number__c=:leadNum and recordTypeId=:RTID limit 2];

 

Thanks,

Santhosh.

Hi,

I have a question. We are using web services API to get leads in to the salesforce. The client application can able to login with the given user name, password and endpoint url and even salesforce is responding back with server url and session id.

The problem is, after logging in, when the client application uses the session id and the server url it gives 'host not found error' error.

I appreciate if anyone can help me on this.

Thanks in advance,
Santhosh.

I am trying to populate a record with the visual force page Url with the custom controller. I am using get parameters in my controller. When I pass values to the url, after some time it is giving me the below error.

 

Time limit exceeded

Your request exceeded the time limit for processing.

 

Our organization has around 1 million records.

 

This is the query i am using in my controller to search for that particular record.

 

LeadNumList = [Select id,name from lead where lead_number__c=:leadNum and recordTypeId=:RTID limit 2];

 

Thanks,

Santhosh.

Hi World,

 

I am sure you will laugh at this  - probably so easy but..... I have  the following trigger - which will insert a case:

 

trigger AutoCreateAccountsCaseSI on Service_Agreement__c (after insert) 
{

if(!StaticClass.flag)
    {
        List<Case> listC = new List<Case>();
        
        for(Service_Agreement__c s : trigger.new)
        if(Trigger.isInsert)
            {
                if(s.HasAccountManager__c = 'Yes' )
                {
                  listC.add(new Case(
                  RecordType='01220000000MEEW',
                  Requested_By1__c=s.OwnerId,
                  Account=s.Related_Account__c,
                  Service_Agreement__c=s.Id,
                  Origin='Salesforce Process',
                  Type='New Account / Service Agreement',
                  Subject='Account Financial Approval',
                  Description='Please confirm reciept of required financial information and approval for service implementation'));
               }
            }
    
        if(listC.size() > 0)
        {
            insert listC;
        }
        StaticClass.flag = true ;
    }
}

 

 However, for some reason i am getting error on the:

 

RecordType='01220000000MEEW',

I have tried with and without quotes, but with quotes I am getting an error of:

 

'Save error: Invalid initial expression type for field RecordType, expecting: SOBJECT:RecordType (or single row query result of that type)'

 

Can any one help??

 

Thanks in advance.

 

 

Steve

 

 

I'm getting the followig error in my test method:

constructor not defined: [AccountOpenCasesExtension].<Constructor>()

 

I instantiated the class file and called my initialize method that is called within the constructor.  I'm not clear on why the constructor is not defined.  Shouldn't the constructor execute when the class is instantiated?

 

Here is my class file:

 

public class AccountOpenCasesExtension { private List<Account> accounts; public List<Account> getAccounts() { return accounts; } public AccountOpenCasesExtension(ApexPages.StandardController stdController) { init((Account)stdController.getRecord()); //accounts = [Select id, name, (Select Owner.Name, Contact.Name, CaseNumber, Subject, CreatedDate From Cases WHERE IsClosed = false) From Account a WHERE id =: stdController.getId()]; } public void init(Account a) { accounts = [Select id, name, (Select Owner.Name, Contact.Name, CaseNumber, Subject, CreatedDate From Cases WHERE IsClosed = false) From Account a WHERE id =: a.Id]; } static testMethod void test() { Account acct = [Select id, name, (Select Owner.Name, Contact.Name, CaseNumber, Subject, CreatedDate From Cases WHERE IsClosed = false) From Account a LIMIT 1]; AccountOpenCasesExtension ctrl = new AccountOpenCasesExtension(); ctrl.init(acct); } }