Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
In this article
Applies to: ✅ Azure Data Explorer ✅ Azure Monitor ✅ Microsoft Sentinel
Convert an energy value from one unit to another.
convert_energy(
value,
from,
to)
Learn more about syntax conventions.
Name | Type | Required | Description |
---|---|---|---|
value | real |
✔️ | The value to be converted. |
from | string |
✔️ | The unit to convert from. For possible values, see Conversion units. |
to | string |
✔️ | The unit to convert to. For possible values, see Conversion units. |
- BritishThermalUnit
- Calorie
- DecathermEc
- DecathermImperial
- DecathermUs
- ElectronVolt
- Erg
- FootPound
- GigabritishThermalUnit
- GigaelectronVolt
- Gigajoule
- GigawattDay
- GigawattHour
- HorsepowerHour
- Joule
- KilobritishThermalUnit
- Kilocalorie
- KiloelectronVolt
- Kilojoule
- KilowattDay
- KilowattHour
- MegabritishThermalUnit
- Megacalorie
- MegaelectronVolt
- Megajoule
- MegawattDay
- MegawattHour
- Millijoule
- TeraelectronVolt
- TerawattDay
- TerawattHour
- ThermEc
- ThermImperial
- ThermUs
- WattDay
- WattHour
Returns the input value converted from one energy unit to another. Invalid units return null
.
print result = convert_energy(1.2, 'Joule', 'BritishThermalUnit')
Output
result |
---|
0.00113738054437598 |