Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

60 Days of Data Days! Live and on-demand sessions, challenges, study groups and more! And it's all FREE!. Join now. Learn more

Reply
Anonymous
Not applicable

Unable to insert,update,delete from GraphQL

I am using Graph Ql, I performing the different CRUD operation. When I am doing single update,insert and delete its working. But when I am trying with multiple rows I am not able to do. Did any one tried it ?

 

Sakshi_Khojare_0-1738308905855.png

 

1 ACCEPTED SOLUTION
v-csrikanth
Community Support
Community Support

Hi @Anonymous 
Thank you for being part of the Microsoft Fabric Community.
If your fabric graphql api allows array-based inserts, you can modify the mutation to accept multiple records:

****************************************************************
mutation CreateEmployees($items: [EmpInput!]!) {
  createempinfo(items: $items) {
    Id
    Name
    Address
  }
}

******************************************************************

JSON

******************************************************************

{
"query": "mutation CreateEmployees($items: [EmpInput!]!) { createempinfo(items: $items) { Id Name Address } }",
"variables": {
"items": [
{"Address": "Pune", "Id": 1000, "Name": "Then"},
{"Address": "Paratwada", "Id": 1001, "Name": "Chetan"}
]
}
}

******************************************************************

 

If the above information helps you, please give us a Kudos and marked the reply Accept as a Solution.

Thanks,
Cheri Srikanth

View solution in original post

4 REPLIES 4
v-csrikanth
Community Support
Community Support

Hi @Anonymous 
We haven't heard from you since last response and just wanted to check whether the solution provided has worked for you. If yes, please accept as solution to help others benefit.
Thank you.

v-csrikanth
Community Support
Community Support

Hi @Anonymous 
Thank you for being part of the Microsoft Fabric Community.
If your fabric graphql api allows array-based inserts, you can modify the mutation to accept multiple records:

****************************************************************
mutation CreateEmployees($items: [EmpInput!]!) {
  createempinfo(items: $items) {
    Id
    Name
    Address
  }
}

******************************************************************

JSON

******************************************************************

{
"query": "mutation CreateEmployees($items: [EmpInput!]!) { createempinfo(items: $items) { Id Name Address } }",
"variables": {
"items": [
{"Address": "Pune", "Id": 1000, "Name": "Then"},
{"Address": "Paratwada", "Id": 1001, "Name": "Chetan"}
]
}
}

******************************************************************

 

If the above information helps you, please give us a Kudos and marked the reply Accept as a Solution.

Thanks,
Cheri Srikanth

nilendraFabric
Super User
Super User

Hello @Anonymous 

 

 

 

 

 

You cannot use the automatically generated GraphQL mutations in Microsoft Fabric to perform inserts, updates, or deletes on multiple rows in a single call because each of those mutations requires a primary key value for one specific row.

 


https://www.mssqltips.com/sqlservertip/8113/crud-operations-in-microsoft-fabric-using-graphql-api-mu...

 

Please accept this solution if this is helpful 

Anonymous
Not applicable

I have used Id as primary key. 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

Fabric Community Sticker Design Challenge Barcelona Carousel

Fabric Community Sticker Challenge - Barcelona 2026

If you love stickers, then you will definitely want to check out our community sticker challenge, Barcelona edition!

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

June Fabric Update Carousel

Fabric Monthly Update - June 2026

Check out the June 2026 Fabric update to learn about new features.