web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

The field cost element of table Sales Line contains a value that cannot be found in the related table(GL Account)

(0) ShareShare
ReportReport
Posted on by

Hi, 

When I try to select a cost element for an item the error The field cost element of table Sales Line contains a value that cannot be found in the related table(GL Account) is generated. I know the Cost element exists in the chart of account but when I try to dill down from the sales line in the stock issue card I cannot see it. I can only see a filtered values for that particular item. The reason could also be a Gen. Posing set up but I tried that one and couldn't work. I am asking if someone experienced the same problem and help me figure out.

Thanks

*This post is locked for comments

I have the same question (0)
  • mmv Profile Picture
    11,471 on at

    Hi,

    Is there any customization in the Sales Line?

  • Community Member Profile Picture
    on at

    Yes, there is a customization in the Sales Line,  the issued card is fully customized which is used to issue items from stores. When I dirlldown in the cost element I can see other GL accounts but others are filtered out.

  • Suggested answer
    Rajasekhar@MS Profile Picture
    5,569 on at

    Can you check by activating the debugger, you will be able to find the code what caused the issue

  • Verified answer
    mmv Profile Picture
    11,471 on at

    So, the value which is displayed in the Sales Line for the moment where you are getting the error is not within the filter applied in either the TableRelation property of the respective field or you need to debug the code.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics NAV (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans