Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Finance forum / Import data through od...
Finance forum
Suggested answer

Import data through odata in a specific company

(0) ShareShare
ReportReport
Posted on by 338
Hi,
 
I am using postman to import data into D365FO but the data is created into the default user company.
I see we can filter based on company while performing GET request but not while POST:https://<D365URL>/data/<DataEntity>.
I am trying to give dataareaid as different company in the body but it doesn't work as well.
 
Thanks!
  • Layan Jwei Profile Picture
    Layan Jwei 4,220 Super User on at
    Import data through odata in a specific company
    Hi Dev,
     
    Can you try with a different environment that is not a Demo? To see if it's a limitation in demo environments.
     
    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • Dev Profile Picture
    Dev 338 on at
    Import data through odata in a specific company
    Hi Layan,
     
    You are right. I tried to post to usmf with empty default company then it posted to DAT.
    Also, I tried to change the crosscompany position as u said but still got the wrong result.
    Now I am wondering what could be the issue as it is a demo env and I do not have dev access to debug.
     
    Thanks!
  • Layan Jwei Profile Picture
    Layan Jwei 4,220 Super User on at
    Import data through odata in a specific company
    Hi Dev,
     
    This shouldn't be the issue. True, Odata returns the data by the user default company,
    However, if you want a different dataArea then you use the cross-company.
    The only difference i can see that you put cross-company after filter while i did it before (not sure if this is the cause)
    And it worked with me even though my user has a default company.
     
    And what if it worked with you because it considered Empty default company as DAT. Try to actually release to usmf now (without default company for the user) and see if it returns dat or usmf.
     
    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • Dev Profile Picture
    Dev 338 on at
    Import data through odata in a specific company
    Hi Layan,
     
    The issue was as the default company was set for the user when I removed that it worked !
  • Suggested answer
    Layan Jwei Profile Picture
    Layan Jwei 4,220 Super User on at
    Import data through odata in a specific company
    Hi Dev,

    I just tried it and it works perfectly. (Make sure you are using the correct url)

    1. I went to product masters and created an item manually of type Product called Test2.
    2. I went to postman, and called the link (url/data/ReleasedProductsV2?cross-company=true&$filter=dataAreaId eq 'dat') as you can see below -- and it returned DAT

    If you are still facing the same issue, maybe try to debug and see why it's not behaving properly of if there is any customization

    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • Dev Profile Picture
    Dev 338 on at
    Import data through odata in a specific company
    HI Layan,
     
  • Layan Jwei Profile Picture
    Layan Jwei 4,220 Super User on at
    Import data through odata in a specific company
    Hi Dev,

    Can you share the "body" here

    Thanks,
    Layan Jweihan
  • Dev Profile Picture
    Dev 338 on at
    Import data through odata in a specific company
    Hi Layan,
     
    This is what is happening for me I set the dataareaid as DAT but the data is still populated in USMF.
     
     
    Thanks!
  • Import data through odata in a specific company
    Educational initiatives like the 12th SLiThEr are invaluable in advancing interactive and engaging teaching practices. These sessions provide a forum for educators to share insights, innovative teaching methods, and resources to enhance the learning experience of students.Professional Development: The SLiThEr series offers a space for professional development, allowing educators to learn from one another. It's an opportunity to explore new teaching techniques and technologies https://writemyessay4you.com/case-study that can make the learning process more dynamic and effective.Interactive Learning: Interactive teaching methods have been shown to improve student engagement and comprehension. SLiThEr sessions encourage the incorporation of such methods, which can range from technology-assisted learning to hands-on activities.
  • Suggested answer
    Layan Jwei Profile Picture
    Layan Jwei 4,220 Super User on at
    Import data through odata in a specific company
    Hi Dev,

    It also works for posting. can you please show us what you did? what's the url you used and what did you fill the body with? and if you are getting an error show it to us.

    I did an example for creating contacts and it works fine (i specified dataArea in the url and not the body)
     

     
    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future

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

Community Spotlight of the Month

Kudos to Mohamed Amine Mahmoudi!

Blog subscriptions now enabled!

Follow your favorite blogs

TechTalk: How Dataverse and Microsoft Fabric powers ...

Explore the latest advancements in data export and integration within ...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 284,876 Super User

#2
Ludwig Reinhard Profile Picture

Ludwig Reinhard Microsoft Employee

#3
Martin Dráb Profile Picture

Martin Dráb 225,425 Super User

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans