sqlserver2012 使用子查詢

2022-09-17 07:15:11 字數 490 閱讀 9358

select

a.成績,a.分數,b.姓名

from 成績資訊 a, 學生資訊 b

where a.學生編號=b.學號 and a.課程編號=『2』 and a.考試編號=『0801』 and a.分數 <(

select **g(分數) from 成績資訊 a,學生資訊 b

where a.學生編號=b.學號 and a.課程編號=『2』 and a.考試編號='

0801

')

select

a.成績,a.分數,b.姓名

from 成績資訊 a, 學生資訊 b

where a.學生編號=b.學號 and a.課程編號=『2』 and a.考試編號=『0801』 and a.分數 in

(select 學號 from 班級資訊 a,學生資訊 b

where a.班級編號=b.所屬班級 and a.班級編號=『201905』)

解除安裝sql server 2012

好不容易裝上了sql server2012資料庫,可是卻不能連線本地的資料庫,後來發現缺少一些服務,於是決定重新安裝,但是解除安裝卻很麻煩,如果解除安裝不乾淨的話,重新安裝會出問題,所以下面就總結一些方法 在解除安裝sql server 2012後,大家都希望能夠將登錄檔資訊完全刪乾淨,下面就將教您...

SQLServer 2012 高效分頁

sql code 功能 生成測試資料.create table test paging id int identity 1,1 not null primary key,testnumber int not null,testname varchar 20 not null,testdept var...

SQL Server2012中的Throw語句

簡 介sql server2012實現了 類似c 丟擲異常的 throw 語句。相比較於 sqlserver2005 之前使用 error,和sqlserver2005 之後使用 raiserror 引發 異常都是乙個不小的 進步,下面來看一下 throw 的用法。raiserror 和throw ...