Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

Insert data of embedded data source on data entity, skip root data source insert

(1) ShareShare
ReportReport
Posted on by
Hello all,
 
I wish to skip data insert of root data source and insert only embedded data source data.
 
I have case with prepayment journal table which has prepayment lines, and each line can have multiple details lines(sublines).
Client wants to add new details lines(sublines) with open to excel and not to insert and new lines or journal.
 
Current approach is data entity with prepayment lines as root data source, because i want to show all lines with no sublines and prepayment sublines as embedded data source.
 
I tried multiple different ways but always get stuck one way or another, did anyone was working on something similar or have idea in what direction should i go?
 
 
I set database operations in mapEntityToDataSource at None for both data sources, and then in subline do manual doInsert() call.
I dont have problem with delete and update but inserting new row always throws error:
A row created in data set PrepaymentInvoiceJournalLines was not published. Error message: 'Bad Request'
  • Error Publishing Row

    Details:
    A row created in data set PrepaymentInvoiceJournalLines was not published. Error message: 'Bad Request'

  •  

    There was an error clearing the table's formatting

    Details:
    The argument is invalid or missing or has an incorrect format.

 
When inserting same data in some other custom method everything is succesfully  saved
 
Best regards

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 Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,017 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,852 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Product updates

Dynamics 365 release plans