• HChauhan
  • NEWBIE
  • 0 Points
  • Member since 2013

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

Need some help on governer limits

Total number of records retrieved by SOQL queries - 50000

 

It is mentioned that total no of records retrieved by SOQL queries in an apex context should be 50000.

I have a large Visualforce page with lots of data displayed in several grids and charts.

It was running fine but now Getting error - reached 50001 rows.

 

Trying to fix this error. Just getting confused about apex context.

does all the queries executed on visual force controllers comes in a single apex context ? If not how the apex engine decide an apex context ?

New to salesforce development. Primarily a dot net developer.

In two or more properties of my controller I want to access values from another controller's properties.

This is how my controller is looking -

 

Controller1 POutlook = new Controller1();

 

 public Decimal currentMonthActualPer {
       get
        {
          return Controller1.currentMonthActualPer;
        }
    }
     public Decimal currentMonthForecastPer {
       get
        {
          return Controller1.currentMonthForecastPer;
        }
    }
    Public String currentMonthBackground{
       get
        {
          return Controller1.currentMonthBackground;
        }
    }
  

 

In my visualfocepage I am accesing this properties directly as -

 

{!currentMonthActualPer} and {!currentMonthForecastPer}

 

Now, I am not sure about Page life cycle of Apex page just wanted to confirm that Apex engine will execute statement -

Controller1 POutlook = new Controller1(); only once or will it call it every time a property's is called(Binded) in visualforce page.

Lot of calculation code has been written Controller1 constructer so just want to execute it once only.

 

Need some help on governer limits

Total number of records retrieved by SOQL queries - 50000

 

It is mentioned that total no of records retrieved by SOQL queries in an apex context should be 50000.

I have a large Visualforce page with lots of data displayed in several grids and charts.

It was running fine but now Getting error - reached 50001 rows.

 

Trying to fix this error. Just getting confused about apex context.

does all the queries executed on visual force controllers comes in a single apex context ? If not how the apex engine decide an apex context ?

New to salesforce development. Primarily a dot net developer.

In two or more properties of my controller I want to access values from another controller's properties.

This is how my controller is looking -

 

Controller1 POutlook = new Controller1();

 

 public Decimal currentMonthActualPer {
       get
        {
          return Controller1.currentMonthActualPer;
        }
    }
     public Decimal currentMonthForecastPer {
       get
        {
          return Controller1.currentMonthForecastPer;
        }
    }
    Public String currentMonthBackground{
       get
        {
          return Controller1.currentMonthBackground;
        }
    }
  

 

In my visualfocepage I am accesing this properties directly as -

 

{!currentMonthActualPer} and {!currentMonthForecastPer}

 

Now, I am not sure about Page life cycle of Apex page just wanted to confirm that Apex engine will execute statement -

Controller1 POutlook = new Controller1(); only once or will it call it every time a property's is called(Binded) in visualforce page.

Lot of calculation code has been written Controller1 constructer so just want to execute it once only.