Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

How to make a job to run for a specific company in Navision

(0) ShareShare
ReportReport
Posted on by 231

Hello everyone,

Scenario: I have a list of companies in native nav database, And a JOB provided to run a report after every 10 mins. Problem is, Manual run of this report provides the desired output , While running it through jobs it takes the data from other companies too. Is there any way to restrict a job to a specific company.

Thank you in advance!

*This post is locked for comments

  • Suggested answer
    Stefano Demiliani Profile Picture
    Stefano Demiliani 37,162 Most Valuable Professional on at
    RE: How to make a job to run for a specific company in Navision

    Have you checked if it’s only a problem where the file (pdf) is stored? Do you have a folder per company? You’ve to check the report code because it can’t be a job queue problem.

    Maybe we can help if you post here the report code.

  • KaryaNavTech Profile Picture
    KaryaNavTech 231 on at
    RE: How to make a job to run for a specific company in Navision

    Hey stefano,

    Yes we have already checked for the CHANGECOMPANY in codes of following codeunit object id:

    1  ApplicationManagement

    448 Job Queue Dispacher

    449 Job Queue Start Codeunit

    but got nothing,

    regarding your query.."If reports scheduled on company A, results comes from company B" only in case of job ques ,on manual run it works fine. And i think user is not an issue its working fine. Any suggestion or Any customization that can be done??

    Thanks a lot for the quick responce..

  • Suggested answer
    Stefano Demiliani Profile Picture
    Stefano Demiliani 37,162 Most Valuable Professional on at
    RE: How to make a job to run for a specific company in Navision

    A task in job queue takes data from the company where the task is. The only case for switching company is when you have instructions like CHANGECOMPANY on code, but I think this is not your case.

    If you have the report scheduled on company A, what's the final result? The data on it comes from which company? Is there something related to the user?

  • KaryaNavTech Profile Picture
    KaryaNavTech 231 on at
    RE: How to make a job to run for a specific company in Navision

    We have a report to generate Number of invoices posted on that day, this report is scheduled to run through job queue and create PDF in different folders.

    The same Job Queue is present in Two companies but start time is different so there wont be any conflict. when we run this report manually it creates PDF in all folders with right company data but when running through job queue it creates PDF but data are taken from another companies.

    Please advice!

  • Suggested answer
    Stefano Demiliani Profile Picture
    Stefano Demiliani 37,162 Most Valuable Professional on at
    RE: How to make a job to run for a specific company in Navision

    Job Queue Entry are per company, so if you have the report scheduled on the company you want (and not also on others) you should receive the output for this company.

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 Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,489 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,305 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans