数据的更改

This commit is contained in:
GuanM 2024-11-19 15:46:08 +08:00
parent 5ce0db0c27
commit 8439ea1f37

View File

@ -0,0 +1,36 @@
-- ********** 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