Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Unanswered

Get trans date payment.

(0) ShareShare
ReportReport
Posted on by 351

Hi all,

Accounts payable<Invoice< pending invoice

Table : vendInvoiceInfoTable.

Accounts payable<Payments< vendor payment journal

Table : LedgerJournalTable

Now, i want to pick pending invoice against payment journal trans date so that i checked both table has relation.

VendImvoiceInfoTable.poolRecid and LedgerJournalTable.Recid.

But, poolRecid set visible no that table. How can I get value ledger journal table? 

I want to pick trans date from LedgerJournalTable table pending invoice against.

Thanks 

  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Get trans date payment.

    Yes you can use the same thread.

    Hi goshoom ,

    Do you have any idea on this.

    Thanks,

    Girish S.

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    Hi Girish i don't know how forward this question Martin sir can you help plz. And i rejected your answer so shall I use same thread?

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    @MartinDráb sir i need your help

  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Get trans date payment.

    Sorry for the late reply. Unfortunately I don't have any valuable suggestion for this.

    Please create separate thread so other community members can help with your scenario.

    Thanks,

    Girish S.

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    Hi Girish,

    I'm waiting for your valuable answer.

    Please help me on this. I'm stuck.

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    Sorry I mislead you actually i want if i post "pending vendor invoice" form and the record will be created from "vendor payment journal".

    I'm working on it in ssrs report.

    TempTable.paymentDate = LedgerJournalTrans.TransDate.

    I saw it while posting class.

    Class name : PurchFormLetter_Invoice

    Now, how can I get LedgerJournalTrans table "TransDate" if pending vendor invoice posted against record?

    Thanks

  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Get trans date payment.

    No as you already said you want to get the pending invoice against the LedgerJournalTrans payment date. That's why I asked you to add while select statement by grouping payment date.

    Also PoolRecId we cannot use since the values is 0 for all the records.

    LedgerJOurnalTrans journal;
    VendInvoiceInfoTable invoiceVendor;
    
    while select * from journal
     Group by journal.PaymentDate
    {
      select * from invoiceVendor 
            where invoiceVendor.ParmJobStatus != ParmJobStatus::Executed
            &&  invoiceVendor.VendInvoiceSaveStatus == VendInvoiceSaveStatus::Pending
            && invoiceVendor.TransDate == journal.PaymentDate;
       infi(strfmt("%1",invoiceVendor.Transdate));
            
    }

    I don't know the exact scenario you are developing. But check whether the above code suits your scenario.

    Thanks,

    Girish S.

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    Hi Girish,

    I have tried code below it's null transDate.

    LedgerJournalTrans localLedgerJournalTrans;
     VendInvoiceInfoTable localVendInvoiceInfoTable;

           
            select firstonly localLedgerJournalTrans
            group by localLedgerJournalTrans.TransDate
            join localVendInvoiceInfoTable where localVendInvoiceInfoTable.PoolRecId == localLedgerJournalTrans.RecId
            &&  localVendInvoiceInfoTable.ParmJobStatus != ParmJobStatus::Executed
            &&  localVendInvoiceInfoTable.VendInvoiceSaveStatus == VendInvoiceSaveStatus::Pending;
           


           
            info(strFmt("%1",localLedgerJournalTrans.TransDate));
    Please give me your example code and i don't know.
    Thanks 
  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Get trans date payment.

    Yes you can give it a try using this method.

    There is also one more option - If you want to get pending invoice against LedgerJournalTrans payment date - Just refer to the below code and check whether it works.

    LedgerJOurnalTrans journal;
    VendInvoiceInfoTable invoiceVendro;
    
    while select * from journal
     Group by journal.PaymentDate
    {
      //add code here to get the pending ivoice against the payment date.  
    }

    I am not sure this will worker but you can try that and see whether its suits your scenario.

    Thanks,

    Girish S.

  • waytod365 Profile Picture
    waytod365 351 on at
    RE: Get trans date payment.

    Hi Girish,

    I have checked LedgerJournalTrans table.

    LedgerJournalTrans.hasPendingInvoice();

    The method inside same code shall i use ? And get it with trans date? Let me know

    Thanks 

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

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Congratulations to the January Top 10 leaders!

Check out the January community rock stars...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,162 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,962 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans