Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested answer

How to populate the data of a different table in another table in Business Central

(0) ShareShare
ReportReport
Posted on by 2,051

Hi all,

I am struggling with a requirement. Client want to store the information of the date of last item sold and added on a particular location.

Requirement : Have to create 2 custom fields on Items table for example let's say Last Sold and Last Received where Last Received field shall return the date of the last PO received date for this item in the location and for the Last sold it shall return the date of the last SO received date for this item in the location.

I tried working with the Flowfield but failed as there are two tables involved Item and Location whereas in flowfield there are limitation and we can't work with 2 tables at a time.

Also, I tried working with OnValidate trigger but unable to find a realtion between the Items and the Location codes. It would be really helpful if anyone can provide a sample code snippet.

Can anyone please suggest a way out?

  • Suggested answer
    JAngle Profile Picture
    95 on at
    RE: How to populate the data of a different table in another table in Business Central

    Is the data you need not in the Item Ledger Entry? All items and the locations where they were shipped or receipted? You have the "Location Filter" as a flowfilter field so anything you produce should use that. I would just copy the "Inventory" field and alter the calcformula according to the logic you have mentioned. Will need to use a sorting to get the correct date.

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Sohail Ahmed Profile Picture

Sohail Ahmed 874

#2
YUN ZHU Profile Picture

YUN ZHU 829 Super User 2025 Season 1

#3
Mansi Soni Profile Picture

Mansi Soni 595

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans