# Missing fields on excel export

**URL:** https://forum.litium.com/t/missing-fields-on-excel-export/2308
**Category:** Questions
**Tags:** field-framework, litium-7
**Created:** [November 15, 2021, 7:06am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308 "2021-11-15T07:06:19Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 15, 2021, 7:06am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/1 "2021-11-15T07:06:19Z")

</div>

We’re having some issues with the excel export where some fields are missing on the product to export. The fields exist on the field template (with no name) but not under product \> fields in settings.

Can’t really re-generate the fields as they cannot be removed. Tried to remove them from the field template but they get added again.

Do I need to delete the field templates?

Litium version: 7.6.1

---

<div class="post-metadata">

### Author: ![patric.forsgard](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/patric.forsgard/32/10_2.png) [@patric.forsgard](https://forum.litium.com/u/patric.forsgard)
#### Post date: [November 15, 2021, 7:34am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/2 "2021-11-15T07:34:53Z")

</div>

It does not exist anything in Litium that automatic create fields, in all similar cases the project have added code to automatic create fields when Litium is starting.

Check the `DefinitionSetup` in the accelerator code to see if that can be the one that are creating the fields.

---

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 15, 2021, 7:55am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/3 "2021-11-15T07:55:35Z")

</div>

I mean we have created the fields some while ago, but they don’t seem to have been generated correctly

---

<div class="post-metadata">

### Author: ![NilsN](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/nilsn/32/302_2.png) [@NilsN](https://forum.litium.com/u/NilsN)
#### Post date: [November 15, 2021, 8:15am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/4 "2021-11-15T08:15:42Z")

</div>

Sounds like you’re updating the field template from code referencing a field that doesn’t exist. Are the missing fields referenced in `ProductsFieldTemplateSetup`?

---

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 15, 2021, 8:28am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/5 "2021-11-15T08:28:58Z")

</div>

Yes, but the field definition for the fields exists and they are referenced in the product field templates. In multiple templates.

---

<div class="post-metadata">

### Author: ![NilsN](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/nilsn/32/302_2.png) [@NilsN](https://forum.litium.com/u/NilsN)
#### Post date: [November 15, 2021, 8:54am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/6 "2021-11-15T08:54:23Z")

</div>

In the default Accelerator fields are only created from code once, there’s a check `IsAlreadyExecuted` that prevents fields from being created multiple times. Maybe the field was removed after it was initially created?

You can delete the key from the `Common.Setting` table (looks like this `acceleratorbuilder:litium.fieldframework.fielddefinition:productarea:weight` for example) or disable the check mentioned above. This would allow the field to be created again from code.

---

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 15, 2021, 9:07am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/7 "2021-11-15T09:07:14Z")

</div>

> [@NilsN](#):
>
> `IsAlreadyExecuted`

Yes, it is that check is already commented, but I will try to delete the key maybe

---

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 17, 2021, 7:28am UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/8 "2021-11-17T07:28:33Z")

</div>

Same issue.

The fields exist in code but are then somehow only generated/added to the template as empty fields

 ![image](https://canada1.discourse-cdn.com/flex030/uploads/litium/original/1X/5aca652a6efee281cc8a5c82b7ac2652c194bbd3.png)

---

<div class="post-metadata">

### Author: ![NilsN](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/nilsn/32/302_2.png) [@NilsN](https://forum.litium.com/u/NilsN)
#### Post date: [November 17, 2021, 3:42pm UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/9 "2021-11-17T15:42:48Z")

</div>

I think you should create a support ticket at [support@litium.se](mailto:support@litium.se) so we can investigate in detail.

---

<div class="post-metadata">

### Author: ![elvir.dzeko](https://avatars.discourse-cdn.com/v4/letter/e/9dc877/32.png) [@elvir.dzeko](https://forum.litium.com/u/elvir.dzeko)
#### Post date: [November 19, 2021, 12:42pm UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/10 "2021-11-19T12:42:29Z")

</div>

Turns out the fields where hidden. The code was probably changed at a point in time, and didn’t update the hidden property for the fields. ☹

Updated the hidden fields in the database (table: FieldFramework.FieldDefinition) and rebuilt the project

Thanks to Nils for the help

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex030/uploads/litium/original/1X/12eddac3b8b661de1db86af10ac8151b571e6fb9.png) [@system](https://forum.litium.com/u/system)
#### Post date: [December 17, 2021, 12:43pm UTC](https://forum.litium.com/t/missing-fields-on-excel-export/2308/11 "2021-12-17T12:43:15Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
