Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics GP (Archived)

How to Join AA and GL table data in SQL

Posted on by 215

For a report I am working on, I need to see GL20000.DSCRIPTN with a query that is pulling info from AAG30000, AAG30001, and AAG30002.  What columns can I use to join these tables?

Thanks in advance for your help!

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: How to Join AA and GL table data in SQL

    Hi Med - I'm trying to do the same thing.  Could you share your results?  Thanks!

  • Med Profile Picture
    Med 215 on at
    RE: How to Join AA and GL table data in SQL

    Hi Ven, Thanks for the help!  Your post helped me figure out what I needed.  Thanks!

  • Verified answer
    26P2ER Profile Picture
    26P2ER 1,773 on at
    RE: How to Join AA and GL table data in SQL

    Hello, Med -

    How about the below

    For your joins?

    AAG30000.JRNENTRY         = GL20000.JRNENTRY      AND

    AAG30000.RCTRXSEQ        =    GL20000.RCTRXSEQ    AND
    AAG30000.aaGLHdrID         = AAG30001.aaGLHdrID   AND

    AAG30001.SEQNUMBER      =GL20000.SEQNUMBER   AND

    AAG30001.aaGLHdrID          =AAG30002.aaGLHdrID    AND

    AAG30001.aaGLDistID         =AAG30002.aaGLDistID

    Best of luck

  • Med Profile Picture
    Med 215 on at
    RE: How to Join AA and GL table data in SQL

    Thank you for the info.  I had reviewed this article prior to posting this question.  The article does not join the AA tables with the GL20000 table.

    I need the JE distribution references with the AA info.  The problem here is that the JE distribution reference is being captured on the GL tables and the users are not using the AA distribution reference in the JE.  So I am tasked with stitching these tables together at the distribution level.  Any other suggestions?

  • Suggested answer
    26P2ER Profile Picture
    26P2ER 1,773 on at
    RE: How to Join AA and GL table data in SQL

    Hello Medardo:

    Mr. Saadi a true AA savant has some ideas here:-

    http://mahmoudsaadi.blogspot.com/2014/03/general-ledger-journals-with-analytical.html

    Best of luck

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans