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 :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Relation between Free text invoice (CustInvoiceTrans) to GeneralJournalEntry table

(0) ShareShare
ReportReport
Posted on by 3,732

Hello,

Can anyone please let me know what is the relation between the Free text invoice (Custinvoicetrans) to GeneraljournalEntry table?

I have the same question (0)
  • Suggested answer
    real_ashwin Profile Picture
    1,229 on at

    Open AOT and check each table to see the relation tab if they are mentioned.

    Anyway I joined them differently you can first join GeneralJournalEntry gje to GeneralJournalAccountEntry gjae using gje.Recid=gjae.GeneralJournalEntry

    Then join GeneralJournalEntry gje and CustInvoiceTrans cit using gje.subledgervoucher=cit.invoiceid and gje.subledgervoucherdataareaid=vij.dataareaid

  • OsmanIstanbul Profile Picture
    2,818 on at

    Hi,

    there is not such a relationship between these two tables. and question has some incorrect informations: free text invoices' table is custinvoicetable. its line table is custinvoiceline.  please check your question and elaborate further.

    Regards.

  • Suggested answer
    greengrimms Profile Picture
    1,400 on at

    Hi Satish,

    I wish there was an easy way to relate transactional data with ledger entries, but the truth is there is no direct 1:1 relation between any of these tables.

    What you can do to get a good match is first search for CustInvoiceJour (header) using the following fields:

    Screen-Shot-2021_2D00_12_2D00_22-at-09.49.24.png

    Then relate the fields LedgerVoucher from CustInvoiceJour with SubledgerVoucher on the GeneralJournalEntry + DefaultDimension from CustInvoiceTrans with LedgerDimension from GeneralJournalAccountEntry (using LedgerDimensionFacade::getDefaultDimensionFromLedgerDimension() in order to get a match between both fields) + LineAmount from CustInvoiceTrans and abs(AccountingCurrencyAmount) from GJAE.

    This of course cannot be translated easily into an x++ query, since it uses x++ functions that don't translate to SQL, but it's the best approximation I could find. 

    Hope that helps.

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 632 Super User 2026 Season 1

#2
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 624

#3
CP04-islander Profile Picture

CP04-islander 301

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans