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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Dynamics 365 Community / Forums / Finance forum / How to filter ledger r...
Finance forum

How to filter ledger records based on financial dimension values

(0) ShareShare
ReportReport
Posted on by 65

Hi, 

I want to filter the ledger report records based on the financial dimensions(main account and cost center) criteria i given on report user request form.

For ex, i have given main account 1001 and cost center ABC but all accounts and cost centers data is displaying on my report.

Can any one help me with some sample code to filter the records based on data i provided.

insert_recordset _ledgerTrialBalanceStagingTmp

                   (GeneralJournalAccountEntry, GeneralJournalEntry, LedgerDimension, Text, AccountingDate, PostingLayer, TransactionType)

               select RecId, GeneralJournalEntry, LedgerDimension, Text from generalJournalAccountEntry

                   order by generalJournalEntry.AccountingDate, generalJournalAccountEntry.IsCredit

               join AccountingDate, PostingLayer from generalJournalEntry where

                   generalJournalEntry.RecId == generalJournalAccountEntry.GeneralJournalEntry &&

                   generalJournalEntry.AccountingDate >= _startDate &&

                   generalJournalEntry.AccountingDate <= _endDate &&

                   generalJournalEntry.Ledger == Ledger::current()

               join Type from fiscalCalendarPeriod where

                   fiscalCalendarPeriod.RecId == generalJournalEntry.FiscalCalendarPeriod &&

                   fiscalCalendarPeriod.Type != FiscalPeriodType::Closing;

I want to apply the financial dimension range on the above filtered records.

Please help me.

Thanks

Satish 

I have the same question (0)
  • Suggested answer
    Mav Profile Picture
    on at

    Did you tried this

    community.dynamics.com/.../164657

  • André Arnaud de Calavon Profile Picture
    301,095 Super User 2025 Season 2 on at

    What exact report are you using (or form)?

  • SatishAX Profile Picture
    65 on at

    I am using in report.

    Thanks

    Satish

  • Suggested answer
    Ludwig Reinhard Profile Picture
    Microsoft Employee on at

    Hello Sathish,

    You can realize this filtering in the trial balance list page. Simply calculate the balances for the period of interest and then show the different findims in separate columns. Once this is done you can export the stuff to Excel or print it. That's possibly the fastest and easiest solution that doesn't need a system modifiation or any other special setup.

    Best regards,

    Ludwig

  • André Arnaud de Calavon Profile Picture
    301,095 Super User 2025 Season 2 on at

    Hi Satish,

    What is the menu path you are using? It is totally not clear what report you are referring to. I do suspect it is related to a Trial balance, but you have to confirm it.

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Finance

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans