cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AkshayManke
Responsive Resident
Responsive Resident

Flow Completing Successfully with Giving Error While Using 'int()' Expression

Hello,

 

We have built a flow in which it checks that if a SharePoint Calculated column field has some value in it (in numbers). If the there is any value then we want to further initiate some actions.

 

Since the field is a calculated column it was initially giving an error hence i have converted it in to Integer using int() expression.

 

Actually i am getting the desired results but the flow is getting failed and showing the below message.

 

InvalidTemplate. Unable to process template language expressions for action '3rd_Month_Total_Check' at line '1' and column '2864': 'The template language function 'int' was invoked with a parameter that is not valid. The value cannot be converted to the target type.'.

 

Going through some references i tried to creating another copy using Save As and ran the flow but got the same error. Can anyone please help how to rectify it?

 

Regards.

10 REPLIES 10
ScottShearer
Super User III
Super User III

@AkshayManke 

I tested your situation and had no issues using int().  If your SharePoint columns allow decimal numbers, you'll want to use the float() expression rather than int().

image.png

 

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

Hello @ScottShearer,

 

Many thanks for help. I tried with changing the Int with float but still same case. The flow is getting stuck in. I have attached the snap for your reference.

 

The flow is running successfully until the condition is true. It gets failed after 2nd false condition. 

 

Ref: The SharePoint column is a Calculated Column | Name = =[Column A]+[Column B]+[Column C]

 

Thanks,

Akshay Error Snap.JPG

@AkshayManke 

Can you provide screen shots of the Flow in Edit mode - the more detail the better especially when it comes to the condition.  Also,  I would like to see how the calculated column is configured.  Can you post a screen shot from the SharePoint list settings showing the calculated column settings?

 

Thanks

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

Hello @ScottShearer, Sorry took more time to answer your question. 

 

Below the snap of condition as requested by you. The cursor is the expression. I have same 12 conditions below to this one (for better organizing, i have created a scope and added them in to it.) 

Condition.jpg

 

 

 

 

 

 

 

 

Below the expression. (I have changed from int to float)

float(body('Update_item')?['OData__x0031_st_x0020_Months_x0020_Tot'])
 
Due to some reason i cant share the calculated column snap. Please let me know if i can give any other information.
 
Thanks,
 

@AkshayManke What is the Column type in SharePoint. Could you please share with screen shot ? Also try int() instad of float once to check what happens 

AkshayManke
Responsive Resident
Responsive Resident

Hi @ajdhingr ,

 

The SharePoint Column is a Calculated Column. If I add Int() then also i get the same error.

 

Thanks,

I will to reproduce the same and issue and will get back to you. 

I tried to repro your issues but unable to get the error . Pleasee check below the details

 

SP List 

ajdhingr_0-1593320336731.png

Condition in Flow on Total 1

ajdhingr_1-1593320409422.png

Result :

ajdhingr_2-1593320450251.pngajdhingr_3-1593320482790.png

 I reckon the key to resolve your issue is to check your SP Columns data type. Please make sure currency is correct or number format is correct and is matching your local settings. 

 

 

AkshayManke
Responsive Resident
Responsive Resident

Hi @ajdhingr , Many thanks for testing and replying on the issue. However i tried the same steps as you shown in the snaps. Also i tried with Float and Int expressions but somehow the flow is getting failed. Will let you know if I get anything.

 

Thanks again!

 

Regards,

If you are still getting the same error then You may raise a support ticket with Microsoft Support Team. They can help to resolve your issue.  

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,373)