+ 6
SQL: SUM, AVG, but what about Division?
In SQL we have functions like SUM, AVG and SQRT But what about other mathematical equations like Division, Minues and Square?
1 Respuesta
+ 4
you can use them in SELECT statements minus -, addition +, division /, and multiple *
SELECT revenue
, expenses
, revenue - expenses AS "Profits"
FROM t_budgets
SELECT price
, ship_cost
, (price + ship_cost) * 1.07 AS "Total"
FROM t_items
this is SQL server at least...