Showing results for 
Search instead for 
Did you mean: 
Frequent Visitor

SQL Issue executing Store Procedure with parameter varchar(8000) in Microsoft Flow



I have a store Procedure below which contains input parameter @customer_Test with varchar(8000).


ALTER PROCEDURE [dbo].[SPTestCustomer]
@company_id VARCHAR(8)
,@inv_mast_uid VARCHAR(2000)
,@prod_group_id VARCHAR(8) = NULL
,@customer_Test VARCHAR(8000)
count(@@ROWCOUNT) NumberofRows

FROM dbo.TableEmp



Now I successfully connected my database using On-Premise Gateway connector. And I am trying to execute my store Procedure through SQL Server "Execute stored procedure (V2)" action as shown below:


But my flow is failing and giving me error "The size (8000) given to the parameter '@Variable3' exceeds the maximum allowed (4000)."



This works well when I remove the input parameter with varchar(8000). Is there any limitation in MS Flow???



Hi @Ankita2020 


You may check the current limitations with the SQL connector here:


Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

I could not see any variable limitation in the link. Please let me know if I am missing anything??

Frequent Visitor

Any Idea about varchar(8000) variable limitation while executing Store Procedure through MS Flow? FYI, we cannot edit the Store Procedure.

@Ankita2020 Did you find a solution for this? im having the exact same. 

I am experiencing the same issue.


Has anyone found a resolution to this issue?


Thank you.

I am experiencing the same issue.


Has anyone found a resolution to this issue?


Thank you.

New Member

Sorry to hijack after so long, but I am in this same situation and am not finding anything anywhere else about this.

Helpful resources

Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Community Calls Conversations

Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (5,765)