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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / how to bypass when bla...
Power Automate
Unanswered

how to bypass when blank value during conversions from excel

(1) ShareShare
ReportReport
Posted on by

Hi Mates,

I have written flow to read and insert in to SQL.

everything is fine but when cell is blank getting below error.

Unable to process template language expressions in action 'Compose_2' inputs at line '1' and column '2266': 'The template language function 'int' was invoked with a parameter that is not valid. The value cannot be converted to the target type.'.

Yes i understand its because of excel cell is blank since it can not convert.

but how can we manage or bypass or when any .... excel cell is blank/empty/null

it should run even it found any blank values

 

Any help here ...?

Categories:
I have the same question (0)
  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    You need to use the empty expression to check whether the value is null or not.

     

    Please have a look at this post.

     

    https://powerusers.microsoft.com/t5/Connecting-To-Data/Check-for-empty-cells-in-Excel/td-p/202544

     

    Thanks

     

     

  • Community Power Platform Member Profile Picture
    on at

    Hi @abm 

    Really thanks for reply,

     

    In my case i am just converting like this  int(outputs('Compose'))

    how to check here then is there any code please..?

  • Community Power Platform Member Profile Picture
    on at

    Hi @abm 

    Can you help me here it shows invalid expression 

    @equals(empty(int(outputs('Compose')),bool(true))

     

    But it throws invalid expression.

    If excel cell value is blank/empty i would like to update blank in SQL column value then iterate next cell to write.

    your help would be highly appreciated.

     

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    image.png

     

     

    image.png

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    See below screenshot then inside the Yes condition you can use int to convert if required using another compose and int expression.

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    Another way to use this is use expression coalesce. If not empty it will return the value. If empty it will default to zero or you can default to a string value then you need to use the single quotes around the default value.

     

    image.png

  • Community Power Platform Member Profile Picture
    on at

    Hi @abm 

     

    Cases which i have tried 

    int(outputs('Compose'),'0')
    int(outputs('Compose'),0)
    but still same error

    Unable to process template language expressions in action 'Compose_2' inputs at line '1' and column '2267': 'The template language function 'int' expects one parameter: the value that is to be converted to an integer. The function was invoked with '2' parameters. Please see https://aka.ms/logicexpressions#int for usage details.'.

     

    coming to the screen shots which you posted 

    if int(output('compse')) is equal to empty  Bool('true')

    if no...

    can loop with excel /conversion value to update. 

    if yes what ...?

    What/how is the condition to update blank, to continue the loop 

     

     

     

  • Community Power Platform Member Profile Picture
    on at

    Hi @abm 

    What is there in if yes condition to update blank...? and continue iterate. 

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    Did you followed by first screenshot which shows the IF condition? Under the Yes condition you can do  int(outputs('Compose')). Then map this output under the SQL mapping.

  • Verified answer
    abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Anonymous 

     

    Try this. If you target data is float use float or int expression accordingly.

     

    if(greater(length(outputs('Compose')),0),float(outputs('Compose')),outputs('Compose'))

     

    Thanks

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 523 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 406 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard