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)

Determine order of batch reports

(0) ShareShare
ReportReport
Posted on by

When printing a batch of reports how is the print order determined?

Examples would be:

Paychecks: How to control whether they print in alphabetical order by name or numeric by check number.

Invoice: How to control whether they print numerically by invoice number or alphabetically by customer name.

Is this controlled by the current key on the table? Or is there some other setting like in request page?

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Suresh Kulla Profile Picture
    50,269 Super User 2026 Season 1 on at

    Rob,

    It will depend on the key you use on the report data item.

  • Community Member Profile Picture
    on at

    Does NAV implicitly use the primary (first) key for this sorting of reports in a batch or do we as devs need to control that inside the page code with SETCURRENTKEY?

    I've got one report that users want to order by a custom field actually defined within the report code (it doesn't stem from the dataItem). Are there alternative or manual ways to override the sorting within the report code?  

    Can reports be sorted by fields not found on their data item tables?

    example: report dataitem uses customer number, users want the report to order by customer name. Customer name is not on the data item for the report. Should it be added at this point or are there c\al methods to apply the sort?

  • Suggested answer
    Suresh Kulla Profile Picture
    50,269 Super User 2026 Season 1 on at

    If you don't specify any key by default it uses the primary key but you can control that using properties of the dataitem by setting the DataITemTableView, or using the SETCURRENTKEY.

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!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics NAV (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans