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
APN09217013342392059APN09217013342392059 

impact of adding namespace on existing code

I am trying out few lightening stuff and as a part of that I added namespace to my Developer edition. After doing this I realized that all my preexisting custom object's API name is now prefixed with the namespace. e.g. object name before adding namespae - MyCustomObject__c object name after adding namespace - MyNamespace__MyCustomObject__c

My existing Apex code which is using MyCustomObject__c is working fine. But any new query that I am firing from dev console requires me to add namespace prefix.

my questions is -

what is the impact of adding namespace ? 1. Do we need to revisit all apex code/soql query ? 2. Do we need to recreate enterprise WSDL and correct SOAP API calls ?

Any insight on this would be very helpful.
KaranrajKaranraj
It won't impact in apex or soql query in apex. But it may affect the followings
1. When you are accessing salesforce API then you need to include the namespace.
2. If you have visualforce contains java script remoting you need to include namespace.
3. If you are calling any apex code from java script  custom buttons.