title: Link GeneralJournalAccountEntryEntity with a Vendor Table
body: <p>I am trying to mimic the Vendor Aging Report in D365 FO in our Warehouse.</p>
  <p>I did identify GeneralJournalAccountEntryEntity as a potential entity for the debit amounts. However this table is at the MainAccounts level.</p>
  <p>I am trying to find an entity which will help me bring it to Vendor Accounts level.</p>
  <p>Question: is this possible? or am I looking at the wrong entities?</p>
  <p>Here are some notable tries:</p>
  <pre><code>select A.*,
  B.*
  from stg_GeneralJournalAccountEntryEntity_ext A
  INNER JOIN  stg_EDMODPurchaseOrderHeaders_ext B ON substring(A.accountdisplayvalue,9,len(A.accountdisplayvalue)) = B.defaultledgerdimensiondisplayvalue
  </code></pre>
  <p>But i see duplications due to Purchase Order No from stg_EDMODPurchaseOrderHeaders_ext</p>