• vamshi Cap
  • NEWBIE
  • 0 Points
  • Member since 2015
  • Mr
  • Cap


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

Hi Folks,

Here is small requirement, I have a picklist fields with different status in visualforce.. every time we change the status, acccording to status we are querying for the values and displaying in table but it is decreasing the perfomance. but instead of querying multiple times I want query once and use muliple time for each change?

Example:
 

for opportunites we have multiple stages ( open, pending, closed), if I want to display open oppys I am using <apex:actionSupport>  on change event I am querying for 'Open records and displaying same for remaining following same, if this is doing 1000 times we are quering 1000 times..but  I want query once but display values again and agian.


please help me it is urgesnt.

 

Vamshi.

Hi Folks,
 

This code eathing my brain, which is overwriting previous values.

global static set<map<string,string>> prepareMigrationData(list<Migration_Object__c> migrationData){
          system.debug('---------'+migrationData);
          map<string,string> XiusMap = new map<string,string>();          
          list<map<string,string>> prepareValue = new list<map<string,string>>();
                   
          if(!util.isempty(migrationData) && migrationData.size()>0)
          {
              for(Migration_Object__c xius: migrationData){
                  system.debug('-----xius----'+xius);
              /******** Field values checking starts here *************/
              if(xius.First_Name__c == null || xius.First_Name__c == '' || xius.First_Name__c == 'None'){
                  XiusMap.put('First_Name__c','XIUS');                 
                  system.debug('-----xius.FirstName----'+xius.First_Name__c);
              }
              else
              { 
                  XiusMap.put('First Name',xius.First_Name__c);
              }
              if(xius.Last_Name__c == null || xius.Last_Name__c == '' || xius.Last_Name__c == 'None'){                  
                  XiusMap.put('Last_Name__c', 'Migration'); 
                  
              }
              else
              { 
                  XiusMap.put('Last_Name__c',xius.Last_Name__c);
              }
              if(xius.emailAddress__c == null || xius.emailAddress__c == ''){
                  XiusMap.put('emailAddress__c','blank@blank.com');
                  
              } 
              else
              {
                  XiusMap.put('emailAddress__c',xius.emailAddress__c);
              }                          
              if(xius.TN__c != null && xius.TN__c != '')
              {
                  system.debug('-----xius.xius.TN__c---'+xius.TN__c);
                  XiusMap.put('TN__c',xius.TN__c);
                  XiusMap.put('Cpnipin__c',xius.TN__c.right(5));
              }
              else
              {
                  XiusMap.put('TN__c','12345');
                  XiusMap.put('Cpnipin__c','12345');
              }
              if(xius.Planshortname__c != null || xius.Planshortname__c != '')
              {
                  XiusMap.put('Planshortname__c',getPlanshortName(xius.Planshortname__c));
              }
              else
              {
                  XiusMap.put('Planshortname__c','');
              }
              if(xius.Shipping_zip__c == '99999' || xius.Servicezip__c == '99999' )
              {
                  XiusMap.put('Shipping_zip__c','99503');
                  XiusMap.put('Servicezip__c','99503');
              }
              if((xius.Servicecity__c =='missing' || xius.Servicecity__c =='MISSING' ||xius.Servicecity__c ==''||xius.Servicecity__c =='missing=address'))
              {
                  XiusMap.put('Servicecity__c', 'Anchorage');                  
              }
              if((xius.Shipping_state__c == 'AL' || xius.Shipping_state__c =='MA' || xius.Shipping_state__c =='WA') || (xius.servicestate__c == 'AL' || xius.servicestate__c == 'MA' || xius.servicestate__c =='WA'))
              {
                  XiusMap.put('Shipping_state__c', 'AK');
                  XiusMap.put('servicestate__c', 'AK');
              }
              if((xius.Serviceaddress__c =='missing' || xius.Serviceaddress__c =='MISSING' || xius.Serviceaddress__c ==''||xius.Serviceaddress__c == 'missing=address'))
              {
                  
                  XiusMap.put('Serviceaddress__c', '2550 Denali St');
              }
                  
              system.debug ('++++++Mapped Vlaues+++++'+XiusMap); // this is showing 5 values differenct
              prepareValue.add(XiusMap); // This map is overwriting and I am firing this method in a batch 5 times, getting all values as same

Hi Folks,

I have requirement in my project.
 

Force we can set a debug logs for 24 hours after 24 hours if we want capture the debug logs we need to set manually. But now I don't want make this manually it should be set automatically daily with batch Jobs and I want to take the back up of all the logs for 24 hours. 

Can you please help me how can I achieve this.

 

Vamshi.

Hi Folks,
 

I did not set debug logs for an User but I want to find the operations performed by the User on a particuar day. Is is possible to query on all objects to find out what an user did on particular day?

Hi I need to fetch the User records on the basis of email Id using SQL queries. Requirement we have three objects.
1. Service
2. Account
3. Cycle30Account.

I have written a query get the email Id from the cyclec30 Account from the service object whose status is suspend.

SELECT Prepaid80__Email_Address__c FROM Prepaid80__Cycle30Account__c where Prepaid80__Account__c in (SELECT Prepaid80__Account__c From Prepaid80__Service__c WHERE Prepaid80__Status__c = 'DISCONNECTED')

now with these email Id I need to fetch User Ids.

 

can please some one help.

 

Vamshi.

Hi Folks,

We would like to update our system admin passwords for our production which is integrated with various application as connected apps and Rest. Is there any impact of the connectivity with external system which are integrated with our applications, if what kind of precautions do we need to take and what kind of changes do we need to do after password update?

What is mean by this error: how can I handle. we already doing null checking,

 For example:

Apex script unhandled exception by user/organization: 00*************TE/00************gRb4
 
Visualforce Page: /apex/ppaccountsummary
 
 
 
caused by: System.NullPointerException: Attempt to de-reference a null object
 
Class.PPOrdersController.<init>: line 17, column 1 
 

In our organization I am working as a developer, I got a new requiement that there was an application which is already running but while developing there might be earlier developer missed out to handle the exceptions, now I stated working on this though I can catch the exceptions and provide user friendly messaged to the User but before deploy, our test team should test this for that I need to provide the proper test criteria or document to test my implimentation. Can you please help me how can I re-produce the same exception with the error message I got in the Past.


The error is: System.Null Exception

In our organization I am working as a developer, I got a new requiement that there was an application which is already running but while developing there might be earlier developer missed out to handle the exceptions, now I stated working on this though I can catch the exceptions and provide user friendly messaged to the User but before deploy, our test team should test this for that I need to provide the proper test criteria or document to test my implimentation. Can you please help me how can I re-produce the same exception with the error message I got in the Past.

 

Thanks.
Nani.

Hi Folks,

I have requirement in my project.
 

Force we can set a debug logs for 24 hours after 24 hours if we want capture the debug logs we need to set manually. But now I don't want make this manually it should be set automatically daily with batch Jobs and I want to take the back up of all the logs for 24 hours. 

Can you please help me how can I achieve this.

 

Vamshi.

Hi Folks,

We would like to update our system admin passwords for our production which is integrated with various application as connected apps and Rest. Is there any impact of the connectivity with external system which are integrated with our applications, if what kind of precautions do we need to take and what kind of changes do we need to do after password update?

What is mean by this error: how can I handle. we already doing null checking,

 For example:

Apex script unhandled exception by user/organization: 00*************TE/00************gRb4
 
Visualforce Page: /apex/ppaccountsummary
 
 
 
caused by: System.NullPointerException: Attempt to de-reference a null object
 
Class.PPOrdersController.<init>: line 17, column 1 
 

In our organization I am working as a developer, I got a new requiement that there was an application which is already running but while developing there might be earlier developer missed out to handle the exceptions, now I stated working on this though I can catch the exceptions and provide user friendly messaged to the User but before deploy, our test team should test this for that I need to provide the proper test criteria or document to test my implimentation. Can you please help me how can I re-produce the same exception with the error message I got in the Past.


The error is: System.Null Exception