cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
sfoerst
Level: Powered On

initialization of a variable float

Does anyone find the mistake in my express?

 

sub(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0'],div(mul(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0'],triggerBody()?['Rabatt']),100))
 
 
 
1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: initialization of a variable float

Hi @sfoerst,

 

When working with math function, you need to make sure the parameter are all numbers, consider use the Int() or Float() function to convert the values, change the formula as below:

sub(
    float(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0']),
    div(mul(
            float(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0']),
            float( triggerBody()?['Rabatt'])
            ),
        100)
)

Function reference.

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Community Support Team
Community Support Team

Re: initialization of a variable float

Hi @sfoerst,

 

When working with math function, you need to make sure the parameter are all numbers, consider use the Int() or Float() function to convert the values, change the formula as below:

sub(
    float(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0']),
    div(mul(
            float(triggerBody()?['Tarif_x003a_Preis_x0028_netto_x0']),
            float( triggerBody()?['Rabatt'])
            ),
        100)
)

Function reference.

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 334 members 5,832 guests
Please welcome our newest community members: