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
pierrefrazny.ax358pierrefrazny.ax358 

Missing dependent object: Field: Opportunity.ContactId

Hello,
I am trying to retrieve the detail records at the same time as the master record. I added a custom field lookup on Opportunity to Account (Contact__c).
 I get this error in Eclipse for the last line of code: "The configuration of your org has changed, please reload the page. Missing dependent object: Field: Opportunity.ContactId".
Could anybody help?
The business scenario that I have is totry to get is the latest Membership_End_Date__c for all Opportunities related to a given Contact.
 Thanks!

trigger UpdateIndividualMemberEndDate on Opportunity (after insert) { set<ID> contIDs = new Set<ID>(); if(Trigger.isInsert) { for(Opportunity o : System.Trigger.new){ contIDs.add(o.Contact__c); } Contact[] conts = new List<Contact>(); conts = [select Id, (select Membership_End_Date__c from Opportunities Order by Membership_End_Date__c desc) from Contact where ID in :contIDs]; Map<Id, Opportunity[]> contopp = new Map<Id, Opportunity[]>(); for (Contact eachCont: conts) { contopp.put(eachCont.Id, eachCont.Opportunities);} } }

 

 
fgwarbfgwarb

I'm dealing with the same issue.  We're doing some validation on user input this is what happens:

 

The user clicks a "next" button the Apex controller code fires and checks their entries, if it succeeds it directs them to the next URL with a pageReference variable.

 

If it fails it returns a null pageReference variable that reloads the page and shows the error messages we've added as ApexPages.Messages so they can make the necessary adjustements.

 

However, on this adjustment page, once they've made their adjustments and click "next" again they'd be redirected to an error screen reporting: The configuration of your org has changed, please reload the page. Missing dependent object: [...details...]

 

 

[..edit...]

I looked through your code to see if there were any similarities between our scripts.  Yours is much more compact, part of my problem is that the code is spread across multiple controllers so most of my time is spent finding the error.

 

Does your SOQL query work through the Sforce Explorer query tool?  I didn't think you could use sub-queries as part of the Select list.  

[...end edit...]

Message Edited by fgwarb on 07-20-2009 03:01 PM
AlsoDougAlsoDoug

Any luck with this?

 

We are having the

 

The configuration of your org has changed, please reload the page. Missing dependent object: Variable: xxxxx : sObjectTypeName

 

problem also.

 

 

pierrefrazny.ax358pierrefrazny.ax358

I was able to fix the issue by renaming the Child Relationship Name field for the custom field I created (lookup to contact on the Opportunity). By default the Child Relationship Name was "Opportunities" and I changes this to "Opportunities2"

 

Hope this helps.

Pierre 

AlsoDougAlsoDoug

Our error is referring to a class in our case that is a abstract apex class (no data/sObject) so probably not the same thing.

 

Thanks though for taking the time to reply :)

 

Doug

 

fgwarbfgwarb

Yes, I was just able to resolve the error.  I fixed the problem by giving the user who was getting the error access to the dependent object.

 

My assumption regarding why the code worked fine the first time through but failed when the error was reported is that the context that the code was being run as changed after the code returned a null pageReference.  I'm assuming the code was running in the system context, and then the pageReference reloaded the code running it as the User.  

 

 

I hope this helps, it was annoying.

AlsoDougAlsoDoug

Hrm now that is interesting.

 

While we get the issue in production we don't get it in sandbox so permissions might be a good guess for our issue also.

 

Of course we are using admin users in both cases but I will check into.

 

Thanks

Doug

 

AlsoDougAlsoDoug

Well we fixed it.

 

We went through ever class/page/component and edited/saved and removed deployed to production.

 

The error then went away.


We had already moved all of the files to production so not sure what it was with edit/saved that did this.

 

I would assume Sales Force does some "compiling" and we forced everything to recompile.

 

Fun.

 

AlsoDougAlsoDoug
Oh yeah also we had some files that were still version 15 and we changed them all to 16.
Anil Kumar SinghAnil Kumar Singh

I also getting similar error with Custom object, and while fixing i found that one custom field is not accessible to my profile.

Please give profile access on eerornious custom field.

 

Hope this may help some one having same problem.

pigginsbpigginsb

These errors were appearing as failures in my unit tests, after I had fetched from git, rebased, and saved updates to server. The debug logs described it as an "Internal Salesforce.com error". They went away when I logged into the portal site and clicked through the recently used pages, then re-ran the tests. Clearing these errors has not increased my understanding of the cause, but I am no longer dealing with them.

Emo514Emo514

I have the same issue. The strange thing is that if I re-save the offending class (literally add some whitespace to the file and save) then the error will disappear for a while.

jvgjvg

I had the same issue with an APEX inner class. Problem went away after I recreated the classes (outer and inner) step by step, starting with just an empty shell and then adding the logic back in. No idea what the root cause is though....

Emo514Emo514

One thing that I noticed is that my class was either referenced by another apex classe or had reference to another custom apex class. When I modified one of the classes, then things got out of sync. When I re-compiled all the classes (using the 'Compile all classes' option on the Apex Classes page) then the error disappeared.

 

In my case once I finished development and deployed, the error hasn't appeared again.

lakshman169lakshman169

I get the same problem in my org.

 

Solution: Change the variable name in your related test method. If using the same variable name in your different test methods you get this error "The configuration of your org has changed, please reload the page. Missing dependent object: Field: "

 

 

sgribisgribi

I ran into this error and the resolution was changing an overloaded method name, that was using an ENUM parameter. Method and variable names seem to be at the core of many odd issues I encountered recently. Clearly I have much to learn.

jjulianjjulian

jvg wrote:

I had the same issue with an APEX inner class. Problem went away after I recreated the classes (outer and inner) step by step, starting with just an empty shell and then adding the logic back in. No idea what the root cause is though....


This solved it for me. This error occured when I tried to rename an inner class. Fixed it by first cutting out the content of the outer class, saving (which does not return any error at this point), pasting back the original content, and saving again.

rekha sharmarekha sharma

As Jvg Said 

I had the same issue with an APEX inner class. Problem went away after I recreated the classes (outer and inner) step by step, starting with just an empty shell and then adding the logic back in. No idea what the root cause is though....

 

I also faced this issue and Step by step creation of on inner class and dependent one resovle the issue. :)

 

Sunil PalSunil Pal

Hi,

Try to increase the api version of all classes to 29 , For me it solved by doing this.

 

Please try .

Hope you wil find the solution.

 

Thanks