Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Suggested answer

$expand filter is not working for F&O ODATA for SalesInvoice

(1) ShareShare
ReportReport
Posted on by 72
Hello,
 
I am trying to use an ODATA $expand filter to get a full invoice with Header and line but it's not working but same filter working for sales order
 
 
 
Does anyone know what is the issue here?
  • André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,735 Super User 2024 Season 2 on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    Hi,
     
    As Layan mentioned it is not due to a trial account.
     
    I now created copies of the invoice entities and checked my comments below. It is indeed as I can remember. I got it working when the entity key on the header was reduced to 1 field that matched the field name on the entity relation from the line entity to the header.
     
  • Layan Jwei Profile Picture
    Layan Jwei 7,266 Super User 2024 Season 2 on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    Hi Community member,

    it's not because of the trial account. I just tried it myself and i got the same behaviour. It worked for sales orders but it didn't work for SalesInvoiceV2Lines.

    I will need to Investigate when I have the time and get back to you

    Thanks,
    Layan Jweihan
  • Community member Profile Picture
    Community member 72 on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    Hello,
     
    Do you think the problem happened because of I am using a trial account?
  • Suggested answer
    André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,735 Super User 2024 Season 2 on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    Hi,
     
    It isn't an issue with the $expand filter. I think it is an issue with the entity key on the invoice header. This now has three fields where the relation on the invoice lines only has the InvoiceNumber field. 
    I have seen this on another entity before and at that time created copies of the entities having only one field on the entity key of the header, where the relation on the line was also matching the same field.
  • Community member Profile Picture
    Community member 72 on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    Hi Martin Dráb,
     
    No SalesInvoiceV3Lines entity is also not working.
     
    Does anyone know if there is any extra configuration needed from my side or it's problem in $expand filter?
     
  • Martin Dráb Profile Picture
    Martin Dráb 230,466 Most Valuable Professional on at
    $expand filter is not working for F&O ODATA for SalesInvoice
    I don't know if it makes any difference, but I don't think you should be using SalesInvoiceV2Lines. This entity is deprecated and replaced with SalesInvoiceV3Lines.

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

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,466 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans