This is my query:
String query = 'SELECT Project__c, Project__r.Testing_Submitted__c, Project__r.Project_Sub_Phase__c, Project__r.DRD_Submited__c,Protected_Application__r.DRD_Completed__c, Protected_Application__c, Project__r.Id, Project__r.Name, Project__r.Project_Type__c, Project__r.Remark__c, Project__r.Record_Type_Name__c, Project__r.RecordTypeId, Project__r.Project_Actual_Completion__c,Protected_Application__r.Application__c, Project__r.Project_Phase__c, Project__r.Ready_for_Testing__c, Project__r.recordType.DeveloperName, Project__r.Project_Sub_Status__c,Project__r.Certification_was_submitted__c, Project__r.Customer_confirmed_launch_date__c,Protected_Application__r.Application_Type__c FROM ProjectAppLink__c ';
As you can see, it's a long string and I'd like to break it to several parts so it would be easier to read.
I tried using '\n' and '+' but when I try these I then get this error:
line breaks not allowed in string literals
Best Answer
The following should allow you to make your query easier to read.