sqlserver基本增删查语句
use StudentManageDB
go
insert into Students (StudentName,Gender,Birthday,Age,StudentIdNo ,PhoneNumber,
StudentAddress,ClassId)
values('李小璐','女','1989-01-12',26,120229198901121314, '022-88997766','天津河北区',1) select * from Students use SMDB
go
select StudentName,Gender,Age from Students where age <>22 use StudentManageDB
go
update Students set Gender='男',Age=25 where StudentId=10000
select * from Students use SMDB
go
insert into Students (StudentName,Gender,Birthday,Age,StudentIdNo ,PhoneNumber,
StudentAddress,ClassId,CardNo)
values('李小璐','女','1989-01-12',26,120229198901121314, '022-88997766','天津河北区',1,'')
select * from Students
delete from Students where StudentId=100000
delete from Students where StudentId=100013 select * from ScoreList
delete from ScoreList where StudentId=100000 delete from ScoreList
truncate table Students
sqlserver基本增删查语句的更多相关文章
- knockout+MVC+webapi+sqlserver完成增删查改
快过年了,公司的事情较少,想着开始学习点新东西.这段时间一个项目用到了mvc和webapi,然后一直对knockout比较感兴趣,就想着用这个框架做一个小实例.数据库采用的是sqlserver.话不多 ...
- Nhibernate入门篇连接Sqlserver的增删查改
第一步:创建数据库 create table Emp( EmpId int primary key identity, EmpName ), EmpDate date ) 第二步:去官网下载:http ...
- 常用SQL语句(增删查改、合并统计、模糊搜索)
转自:http://www.cnblogs.com/ljianhui/archive/2012/08/13/2695906.html 常用SQL语句 首行当然是最基本的增删查改啦,其中最重要的是查. ...
- EF各版本增删查改及执行Sql语句
自从我开始使用Visual Studio 也已经经历了好几个版本了,而且这中间EF等框架的改变也算是比较多的.本篇文章记录下各个版本EF执行Sql语句和直接进行增删查改操作的区别,方便自己随时切换版本 ...
- EF增删查改加执行存储过程和sql语句,多种方法汇总
ActionUrl c = new ActionUrl() { ActionName="test", RequestUrl="/123/123", SubTim ...
- 2015.8.2 jdbc实现商品类的增删查改
在惠普济宁基地进行了两周sql和java的学习,学到很多东西 刚才实现了用jdbc访问数据库对数据库进行操作,是用eclipse写的,过几天移植到NetBeans上,个人还是比较习惯看图形化界面 前几 ...
- C# SQLite 创建数据库的方法增删查改语法和命令
SQLite介绍 SQLite是一个开源.免费的小型RDBMS(关系型数据库),能独立运行.无服务器.零配置.支持事物,用C实现,内存占用较小,支持绝大数的SQL92标准. SQLite数据库官方主页 ...
- 3.EF 6.0 Code-First实现增删查改
原文链接:http://www.c-sharpcorner.com/UploadFile/3d39b4/crud-operations-using-entity-framework-5-0-code- ...
- 4.在MVC中使用仓储模式进行增删查改
原文链接:http://www.c-sharpcorner.com/UploadFile/3d39b4/crud-using-the-repository-pattern-in-mvc/ 系列目录: ...
随机推荐
- React中jquery引用
安装jQuery npm i jquery -S 在那个地方使用jQuery就在什么地方引入jQuery import $ from 'jquery'
- C++中的抽象类
一.抽象类学习笔记 1.virtual修饰函数(虚函数)后面加=0就称为一个纯虚函数,一个类中只要有纯虚函数那么它就是一个抽象类.抽象类不能用来实例化对象,是用来给他的派生类定义好这些框架的,给使用这 ...
- How to get checksum by IAR
- Be Careful When Using Bit Field
Below illustration is based on MSP430, IAR. See the implementation below. typedef struct { uint8_t g ...
- .NET本质论 用类型编程
运行时的类型 类型本身并不是万能的.类型真正有意思的地方在于,程序员使用类型的实例,并让它们相互作用.类型的实例(instance)既可以是对象,也可以是值,这取决于类型如何定义的.基本数据类型(pr ...
- 自动化部署--shell脚本--2
node1和node2都装apache [root@linux-node1 ~]# yum install httpd -y Loaded plugins: fastestmirror Loadi ...
- python生成随机数、随机字符串
python生成随机数.随机字符串 import randomimport string # 随机整数:print random.randint(1,50) # 随机选取0到100间的偶数:print ...
- 2019.4.11 一题 XSY 1551 ——广义后缀数组(trie上后缀数组)
参考:http://www.mamicode.com/info-detail-1949898.html (log2) https://blog.csdn.net/geotcbrl/article/de ...
- Eureka的高可用
问题: 现在Eureka和Client是1对1,但是Eureka挂了,就不能用了. 如何解决呢,创建多个Erurka.并且Eureka进行相互注册.如下图 怎么相互注册呢 1. 创建两个Eureka ...
- MySQL 5.7 Invalid default value for 'CREATE_TIME'报错的解决方法
出处:http://blog.itpub.net/15498/viewspace-2136006/ 由于数据库的升级,今天在执行从MySQL 5.6导出来的SQL文件时报错: mysql> so ...