2024-11-19 15:46:08 +08:00

36 lines
797 B
Bash

-- ********** create database ********** --
-- ********** Begin ********** --
create database Books
-- ********** End ********** --
go
use Books
go
-- ********** create table ********** --
-- ********** Begin ********** --
create table prices
(
ID int IDENTITY(1,1) not null,
Name varchar(20) not null,
price varchar(30) not null
)
-- ********** End ********** --
go
SET NOCOUNT ON
-- ********** insert ********** --
-- ********** Begin ********** --
insert into prices (Name, price) values ('Harry Potter', '$128')
insert into prices (Name, price) values ('Walden', '$5')
-- ********** End ********** --
go
SET NOCOUNT ON
-- ********** update ********** --
-- ********** Begin ********** --
update prices set price = '$6' where Name = 'Walden'
-- ********** End ********** --
go