• Jesus Alvarado
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 3
    Replies
   
 Hi Experts,
 
 I need to change the format of Installation_Date__c into YYYY-MM-DD,here is the code where Installation_Date__c field is used , could anyone help me please
   
   
   for(TWM_Meter__c meter : [select id, Meter_Location__c, Meter_Box_Type__c, Exact_location_of_Meter__c, Meter_Grid_Ref_No__c,
                                            Serial_No__r.Name, In_Line_or_Concentric__c, Meter_Make__c, Meter_Type__c, Meter_Size__c, Flow_Rate__c, No_of_Dials__c,
                                            Manufactured_year__c, Last_Reading__c,  Installation_Date__c, LCE_Fitted__c, LCE_Reader_Serial_No__c,
                                            LCE_Location__c, LCE_Grid_Ref__c, New_Radio_ID__c,  Pulse__c, Property_Outer_Postcode__c,Property_Inner_Postcode__c,
                                            Northings__c, Eastings__c, Exchange_Radio_ID__c, Task__r.Job__c, 
                                            Meter_Location_Description__c, Task__r.name, // CH04 
                                            Tech_Type__c,DMA__c,MIU_fitted__c,New_MIU_Reader_Serial_Number__c,MIU_location__c,MIU_Grid_ref__c from TWM_Meter__c where  Task__r.Job__c in : mapJobTasks.keySet()
                                            AND ((Installation_Date__c >=:twmJobInst.Required_Start_Date__c //CH09
                                            AND Installation_Date__c <=:twmJobInst.Required_Completion_Date__c)//CH09
                                            OR (Installation_Date__c = null))//CH09
                                            order by Task__r.name]){ //CH04 Added order by     // CH06.New 
                                            
                                            
                                            
  strItemRow += formatDate(meter.Installation_Date__c) + '|';