1

I get the following error when I try to create a 2GP version using SF CLI.

No such column 'Mynamespace__Opportunity__c' on the 'Mynamespace__Contract__c' entity. If you're trying to use a custom field, make sure you add the '__c' after the custom field name. Please refer to your WSDL or description call for the appropriate names.

the error was : `No such column 'Opportunity__c' on entity 'Mynamespace__Contract__c'. If you're trying to use a custom field, make sure you add the '__c' after the custom field name. Please refer to your WSDL or description call for appropriate names. I tried to: 1- manually add the namespace to the field.

The query string that causes this problem is SELECT Id, Name, GDevOps__Opportunity__c FROM Contract__c' ;

2- rename the package directories from force-app to customName and modify the definition file to refer to

This is the full error output:

Quote_Utils: Contract__c WHERE Id IN :record_ids AND RecordType.DeveloperName IN ('Broker'                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       
                                         ^                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        
 ERROR at Row:1:Column:56                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         
 Didn't understand relationship 'RecordType' in field path. If you are attempting to use a custom relationship, be sure to append the '__r' after the custom relationship name. Please reference your WSDL or the describe call for the appropriate names.                                                                                                                                                                                                                                                                                                                                                                        
 QuoteSpecification_Handler: Dependent class is invalid and needs recompilation:                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
  Class GDevOps.Quote_Utils :                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     
 Contract__c WHERE Id IN :record_ids AND RecordType.DeveloperName IN ('Broker'                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
                                         ^                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        
 ERROR at Row:1:Column:56                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         
 Didn't understand relationship 'RecordType' in field path. If you are attempting to use a custom relationship, be sure to append the '__r' after the custom relationship name. Please reference your WSDL or the describe call for the appropriate names.                                                                                                                                                                                                                                                                                                                                                                      `         ``                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               
 

1 Answer 1

0

I understand your problem. I think this error msg starts with 'Apex Test Failure'. I had a similar problem. Changing the sfdx-project.json file helped me. I added "apexTestAccess".

enter image description here

If this does not help, then try to provide more details.

2
  • unfortunately, it does not work for me. i still have the same issue.
    – Paco
    Commented May 2 at 10:02
  • @Paco, provide the full text of the error, along with where it occurred.
    – Nazar
    Commented May 3 at 10:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .