Skip to main content

Notifications

Dynamics 365 Community / Forums / Finance forum / Custom data entity bui...
Finance forum
Suggested answer

Custom data entity build error "field not specified"

editSubscribe (2) ShareShare
ReportReport
Posted on by 169
Hello,

I have made my own data entity for EmploymentPerCompany as the one that exists have a preconfigured “Key” that does not work for me and it is my understanding that it is then best practice to make you own.

I have added all of the same relationsships and fields to the dataentity but one of the fields have given me a lot of problems as it wont build.


The field is “ValidTo” that I have taken from the Data Source HcmEmploymentDetail.
When building I get the following error:


I have also added “ValidFrom” which builds fine.

I have tried the following:
  1. I have checked that everything is configured as on the original HcmEmploymentPerCompanyEntity à HcmEmploymentDetail.
  2. The fields ValidFrom and ValidTo has the exact same properties set.
  3. I have rebuilt the models
  4. I have updated the database.
  5. I have even deleted the “ValidTo” and “ValidFrom” fields from my entity but then I get even more error on build:
 
  • Layan Jwei Profile Picture
    Layan Jwei 3,079 Super User on at
    Custom data entity build error "field not specified"
    Hi,
     
    Is your issue fixed?
     
    Thanks,
    Layan Jweihan
  • Layan Jwei Profile Picture
    Layan Jwei 3,079 Super User on at
    Custom data entity build error "field not specified"
    Hi,

    What do you mean by this "have a preconfigured “Key” that does not work for me"? what key are u referring to? 

    ​​​​​​​What is your new Entity key for this entity? is it different than the original one?

    Also, If you are sure you need to create a new entity, then does the original entity contain validFrom and validTo fields? if yes then why did you create it from scratch? just do the following:

    1. Duplicate the entity in your project
    2. Duplicate the staging table in your project
    3. Rename the entity and the staging table
    4. change the label of the staging table
    5. change the label of the entity, in addition to it's public collection name and public entity name
    6. link the new entity to the new staging table name by changing "Data management staging table" property on the entity
    7. Remove the fields or data sources that u don't need from the new entity and the new staging table

    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • CU06050518-1 Profile Picture
    CU06050518-1 5 on at
    Custom data entity build error "field not specified"
    Hi all. I have tried all of the mentioned solution. Nothing worked :( 

    1. I made sure to change label, public entity name and the staging table is reading from my new entity. 

    2. I have even tried to delete the data entity, creating it again from scratch. I then tried to build before adding any fields from the data sources. and i got the same error with the two date fields. So the error happens before i add the fields. The only thing i have done at that point is setting up the data entity with its data sources using the exact same relationships as used in the original data entity
  • Suggested answer
    Waed Ayyad Profile Picture
    Waed Ayyad 2,510 on at
    Custom data entity build error "field not specified"
    Hi,
     
    Did you change the label, public entity name, collection name of the entity, and relationships on the entity and staging table to read from your new entity?
     
     
    Thanks,
    Waed Ayyad
    If this helped, please mark it as "Verified" for others facing the same issue
     
  • Suggested answer
    Deepak Agarwal Profile Picture
    Deepak Agarwal 127 on at
    Custom data entity build error "field not specified"
    These both are std field enabled by table property as below.
    I would recommended , first check if you really need these fields in data entity, because these fields are maintained by system. Also these fields controls the data you may get , only active or valid data can be fetched with normal query. 
     
    You can give a try to add a date field manually and set the property to this table field. 
  • Suggested answer
    Mohamed Amine Mahmoudi Profile Picture
    Mohamed Amine Mahmoudi 4,311 User Group Leader on at
    Custom data entity build error "field not specified"
    Hi,
     
    I believe the ValidFrom and ValidTo fields are used by the standard.
    I suggest you change the field names and try to build with synchro.
     
    Best regards,
    Mohamed Amine MAHMOUDI

Helpful resources

Quick Links

Take the Community feedback survey!

Answer this brief 15-question survey about your Community experience…

Demystifying Copilot: Service Edition with Sundar Raghavan

Sundar answers more questions about Copilot for Service...

Dynamics 365 Business Central vs Finance and SCM

Take a look at the key differences between Business Central and…

Leaderboard

#1
Andre Arnaud de Calavon Profile Picture

Andre Arnaud de Cal... 283,375 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 223,308 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,140

Featured topics

Product updates

Dynamics 365 release plans