function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Atlantic Technologies 9Atlantic Technologies 9 

FSL service report language

Hi,

we are facing a problem regarding the ServiceReportLanguage field on WorkOrder object.
We tried to update via Apex

Workorder w = new Workorder(ServiceReportLanguage = 'FR');
insert w;

The system raised this error:

{ "column": "15", "compileProblem": "Field does not exist: ServiceReportLanguage on WorkOrder", "compiled": "false", "exceptionMessage": "", "exceptionStackTrace": "", "line": "1", "success": "false" }

We also tried to query using a Workbench:

select id, ServiceReportLanguage from workorder limit 1

but we faced this error:

INVALID_FIELD: 
select id, ServiceReportLanguage from workorder

ERROR at Row:1:Column:12
No such column 'ServiceReportLanguage' on entity 'WorkOrder'. If you are attempting to use a custom field, be sure to append the '__c' after the custom field name. Please reference your WSDL or the describe call for the appropriate names.

T&R,
Giuseppe.
SandhyaSandhya (Salesforce Developers) 
Hi,


Check the API version of your class that makes the dynamic query. The Work Order object was introduced in API v36.0, so if your class is v35.0 or earlier, it will not be aware of the existence of the Work Order object.Try to query in developer console.

https://developer.salesforce.com/forums/?id=906F0000000D8WyIAK
 
Please mark it as solved if my reply was helpful. It will make it available for other as the proper solution.
                                             
Best Regards
Sandhya