This is to add a column in a table with calculated values from the same table.
ALTER TABLE pedidos add column impuesto float generated always as (subtotal*.16) VIRTUAL;
ALTER TABLE pedidos add column total float generated always as (subtotal*1.16) VIRTUAL;
ALTER TABLE pedidos add column flete float generated always as (case when total < 6000 then 1000 else 0 end) virtual