web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

sending OData post to insert data returns already exist

(0) ShareShare
ReportReport
Posted on by 45

Hi all.

I am trying to insert a simple row in Account Schedule. Schedule Name is already created in Account Schedules page. Issue is when i use postman to send data to account Schedule., I get following error

{
    "error": {
        "code": "Internal_EntityWithSameKeyExists",
        "message": "The record in table Acc. Schedule Line already exists. Identification fields and values: Schedule Name='',Line No.='10001'  CorrelationId:  eb85b786-d673-47d1-b43b-71b518998691."
    }
}

My request body looks like this:

{
	"Schedule_Name": "IC1",   /// It is already in Account Schedules
	"Line_No": 10001,
    "Row_No": "10",
    "Description": "Total Revenue",
    "Totaling_Type": "Posting Accounts",
    "Totaling": "40100..40400",
    "Row_Type": "Balance at Date",
    "Amount_Type": "Net Amount",
    "Show_Opposite_Sign": false,
    "Dimension_1_Totaling": "",
    "Dimension_2_Totaling": "",
    "Dimension_3_Totaling": "",
    "Dimension_4_Totaling": "",
    "Show": "Yes",
    "Bold": false,
    "Italic": false,
    "Underline": false,
    "Double_Underline": false,
    "New_Page": false
}

Is it because of composite keys or Schedule Name is coming from related Table?

Please point me in right direction to resolve this issue.

Regards

I have the same question (0)
  • Suggested answer
    Marco Mels Profile Picture
    Microsoft Employee on at

    Hello,

    Does the same issue happen when using "Edit in Excel"?

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at

    POST is an Insert operation, so here it seems that you're posting a record with the same primary key.

  • sami khan Profile Picture
    45 on at

    There is no action called "Edit in Excel"

  • sami khan Profile Picture
    45 on at

    Steano Thanks for reply. It is a composite key with fields "Schedule Name" and "Line No.". As you can see in Json. I am providing values for both. But in response Schedule Name is empty while Line No. has value.

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at

    Please check that:

    - you don’t have a record with those primary key values

    - if the record is not present, please check if you have code in OnValidate or OnInsert triggers that does something.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 1,850 Super User 2026 Season 1

#2
YUN ZHU Profile Picture

YUN ZHU 1,045 Super User 2026 Season 1

#3
Dhiren Nagar Profile Picture

Dhiren Nagar 959 Super User 2026 Season 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans