CONVERT converts a value from one unit of measurement to
a different unit of measurement.
Syntax
CONVERT(number,from_unit,to_unit)
- number is a value.
- from_unit specifies the measurement unit from
which to convert. from-unit is a unit name from the following table,
entered as text enclosed in " " (quotation marks).
- to_unit specifies the measurement unit to
which to convert. to-unit is a unit name from the following table,
entered as text enclosed in " " (quotation marks).
Unit names are case-sensitive. CONVERT returns #N/A if either
from_unit or to_unit does not match a unit name from the following
tables. CONVERT also returns #N/A if from_unit and to_unit are
from different unit groups.
Table 1. Unit names for mass group
Unit name |
Mass |
g |
Gram |
sg |
Slug |
lbm |
Pound mass (avoirdupois) |
u |
U (atomic mass unit) |
ozm |
Ounce mass (avoirdupois) |
Table 2. Unit names for distance group
Unit name |
Distance |
m |
Meter |
mi |
Statute mile |
Nmi |
Nautical mile |
Pica |
Pica |
in |
Inch |
ft |
Foot |
yd |
Yard |
ang |
Angstrom |
Table 3. Unit names for time group
Unit name |
Time |
yr |
Year |
day |
Day |
hr |
Hour |
mn |
Minute |
sec |
Second |
Table 4. Unit names for pressure group
Unit name |
Pressure |
Pa |
Pascal |
atm |
Atmosphere |
mmHg |
mm of mercury |
Table 5. Unit names for force group
Unit name |
Force |
N |
Newton |
dyn |
Dyne |
lbf |
Pound Force |
Table 6. Unit names for energy group
Unit name |
Energy |
J |
Joule |
e |
Erg |
c |
Thermodynamic calorie |
cal |
IT calorie |
eV |
Electron volt |
HPh |
Horsepower-hour |
Wh |
Watt-hour |
flb |
Foot-pound |
BTU |
BTU |
Table 7. Unit names for power group
Unit name |
Power® |
HP |
Horsepower |
W |
Watt |
Table 8. Unit names for magnetism group
Unit name |
Magnetism |
T |
Tesla |
ga |
Gauss |
Table 9. Unit names for temperature group
Unit name |
Temperature |
C |
Celsius |
F |
Fahrenheit |
K |
Kelvin |
Table 10. Unit names for liquid group
Unit name |
Liquid |
tsp |
Teaspoon |
tbs |
Tablespoon |
oz |
Fluid ounce |
cup |
Cup |
pt |
Pint |
qt |
Quart |
gal |
Gallon |
l |
Liter |
The prefixes (entered with " " marks) listed in the following
table are also valid for units. CONVERT returns #N/A if the unit does
not support a prefix.
Table 11. Unit prefixes
Prefix |
Description |
Multiplier |
E |
exa |
1E+18 |
P |
peta |
1E+15 |
T |
tera |
1E+12 |
G |
giga |
1E+09 |
M |
mega |
1E+06 |
k |
kilo |
1E+03 |
h |
hecto |
1E+02 |
e |
dekao |
1E+01 |
d |
deci |
1E-01 |
c |
centi |
1E-02 |
m |
milli |
1E-03 |
u |
micro |
1E-06 |
n |
nano |
1E-09 |
p |
pico |
1E-12 |
f |
femto |
1E-15 |
a |
atto |
1E-18 |
Example
CONVERT(10, "C", "F") returns 50
CONVERT(1,"sec","msec") returns 1000