AnswerBun.com

No such field ActivityOriginType even though returned through field map

Salesforce Asked by Tyler Dahle on January 4, 2022

We have an all fields query that gets the field map from an object’s describe in Apex. It then loops over the map and assembles a query.

In one clients org, the field map is spitting out ActivityOriginType on the Task, but then when the query goes, we get this:

System.QueryException: No such column 'activityorigintype' on entity 'Task'.

We had issues with things like LastViewedDate where the field map gave out that field, but it wasn’t actually accessible because there wasn’t a tab for the object. Enabling the Enable Improved Caching of Org Schema critical update fixed issues with LastViewedDate but apparently isn’t fixing issues with this ActivityOriginType field.

Does anyone know where this field came from and how you can get around this? My concern with adding it to a set of fields to leave out of the query is: I don’t know how many of these weird hidden fields exist on various objects or if new ones will be added so the set will continuously need updating.

Is there a way to just toss them out? Is there something that can be done in the org to fix this issue with this field without a new package?

Add your own answers!

Related Questions

Apex Regex Extract Numeric Value from String

3  Asked on January 6, 2022 by yossi-cadaner

 

Ignore files when force:source:convert

4  Asked on January 6, 2022 by simonp

 

AuthToken using Open Id Connect

1  Asked on January 6, 2022 by bergin-panimayam

     

Using IsPickVal() function inside Email Templates

1  Asked on January 6, 2022 by anthony-williams

       

Create record by submitting string for reference field

1  Asked on January 4, 2022 by user85715

 

Ask a Question

Get help from others!

© 2023 AnswerBun.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP