By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
create table invoice_data(
id int primary key AUTO_INCREMENT,
description varchar(100)
);
create view invoices as
select
15 * id as invoice_number,
description
from invoice_data;
insert into invoice_data (description) values
('invoice 1 information'),('invoice 2 information');
select * from invoices;
invoice_number | description |
---|---|
15 | invoice 1 information |
30 | invoice 2 information |