有 學生 表 由學號,姓名,性別,出生日期,所在系屬

2021-08-26 16:13:32 字數 4423 閱讀 6131

1樓:

1.create table 學生

(學號 char(8),

姓名 char(8),

性別 char(2),

所在系 char(10),

出生日期 datetime)

2.insert into 學生

values('12001001','張紅','女','經濟系','2023年12月25日')

3.select 學號,姓名 from 學生 where 性別='男'

4.select 姓名,所在系 from 學生 where 出生日期》'2023年1月1日'

5.select 姓名,學號,性別 from 學生 where 姓名 like '劉%'

2樓:襠下憂鬱丶

create table student (xh varchar(8),

xm varchar(8),

xb varchar(2),

szx varchar(10),

csrq date

);insert into student (xh,xm,xb,csrq,szx) values ('12001001','張紅','女','1992-12-15','經濟系')

select xh,xm student where xb='男'

select xm,szx student where csrq>'19931-1'

select xm,xh,xb student where xm like '劉%'

有一個[學生課程]資料庫,資料庫中包括三個表 50

3樓:小小猿愛嘻嘻

create table 學生表

(學號 varchar(12) not null,姓名 varchar(20) not null,性別 varchar(10) not null,年齡 int check(年齡》=0 and 年齡<=120),所在系 varchar(20) not null,primary key (學號)

)create table 課程表

(課程號 varchar(12) not null,課程名 varchar(20) not null,先修課號 varchar(20) not null,學分 int check(學分》0 and 學分<=20),primary key (課程號)

)create table 成績表

(學號 varchar(12) not null,課程號 varchar(12) not null,成績 real check(成績》=0 and 成績<=100),primary key (學號,課程號),foreign key (學號) references 學生表 (學號),

foreign key (課程號) references 課程表(課程號))

4樓:匿名使用者

1: 學生表

create table student

(s# int primary key,

name char(80),

*** char(20),

age int,

dept char(50)

)2課程表

create table course

(c# int primary key,

cname char(50),

kh char(50),

score numeric(5,2)

)3成績表

create table sc

(s# int primary key,

c# char(50) not null,score numeric(5,2))

5樓:匿名使用者

你要用這三個表做什麼呢?

要建立一個資料庫表,是學生表student由學號(sno)、姓名(sname)、性別(s***)、年齡(sage)

6樓:匿名使用者

首先char,int這些為欄位資料型別,

char是指:使用指定長度的固定長度表示的字串;比如char(20),則資料庫會使用固定的20個位元組來儲存資料,不足20位的字串在其後補空字元;

int:是整形

有一個「學生-課程」資料庫,資料庫中包括三個表: (1) 「學生」表s由學號(sno)、姓名(sname)、性別

7樓:

1.從庫中查詢計算機系選修資料庫基礎與應用的學生的學號、姓名、成績,按學號遞增專排序,存入遊屬標student中,只讀。

2.查詢資訊工程系學生的年齡。

3.cover的這個啥沒學過就幫不上忙了~等待高人吧4.(貌似)如果讀取的數值為0,則不允許刪除且允許定義新值ps:不是很肯定,你可以再參考下其他人的答案~

有一個學生資料庫,有以下關係模式構成: 學生(學號,姓名,性別,年齡,所在系)

8樓:匿名使用者

1)select a.學號,a.成績 from 選修 a, 課程來自 b

where a.課程號=b.課程號 and b.課程名='3號' order by a.成績 desc

-- 如果不是按課程名查,可以不用連線"課程"表2) select a.課程號, b.課程名, count(a.學好) from 選修 a, 課程 b

where a.課程號=b.課程號

group by a.課程號, b.課程名3)select b.

姓名 from 選修 a, 學生 bwhere a.學號=b.學號 and a.

成績 > 904)insert into 學生(學號,姓名,性別,年齡,所在系) values ('012508','劉敏','女',18,'計算機')

9樓:匿名使用者

1.select 學生bai.學號

,成績du

from 學生,選修,課程

zhiwhere 課程名="3號課dao程" and 學生.學號專=選修.學號 and 選修.課程號屬=課程.課程號

order by 成績

2.select 課程號,count(學號) as 人數from 選修

group by 課程號

3.select 姓名

from 學生,選修,課程

where 學生.學號=選修.學號 and 選修.課程號=課程.課程號 and 課程名="2號課程" and 學分》=90

4.insert into 學生 values ('012508','劉敏','女','18','計算機')

6. 有一個「學生-課程」資料庫,資料庫中包括三個表: (1) 「學生」表student由學號、姓名、性別、年齡、

10樓:逆鱗天團

6.有一個「學生-課程」資料庫,資料庫中包括三個表:

(1)「學生」表student由學號、姓名、性別、年齡、所在系五個屬性組成,可記為:

student(學號,姓名,性別,年齡,所在系),學號為關鍵字。

(2)「課程」表course由課程號、課程名、先修課號、學分四個屬性組成,可記為:

course(課程號,課程名,先修課號,學分),課程號為關鍵字。

(3)「學生選課」表sc由學號、課程號、成績三個屬性組成,可記為:

sc(學號,課程號,成績),(學號,課程號)為關鍵字。

完成下列操作:

a請把其中建立「學生」表student的語句寫下來,表student是由學號、姓名、性別、年齡sage、所在系五個屬性組成,其中學號屬性不能為空,並且其值是唯一的。

b在student表中查詢所在系是『計算機』的學生的所有資訊,並按學號降序排列。

c在以上三個表中查詢學分為5並且成績大於60的學生的學號、姓名和性別。

定義一個表示學生的類student,包括屬性:學號,姓名,性別,年齡;

11樓:肥仙女

1、新建一個272.php,如圖所示:

2、輸入php網頁的結構(<?php?>),如圖所示:

3、宣告php與瀏覽器互動的檔案型別和編碼,如圖所示:

4、使用class關鍵字,定義一個student類,**如圖所示:

5、給student類新增成員變數和成員方法,**如圖所示:

6、給student類,建立一個物件,**:$s1=newstudent()。

12樓:匿名使用者

public class student

public int getstunum()public int getname()

public char get***()

public int getage()

public void setage(int age)}

excel問題 有一張表 姓名 學號 科目 成績 想變成 姓

用vba吧,你提出的這個型別一般資料量都比較大的。應該不止這幾門成績的統計吧。下面的 複製到vba中執行即可 sub scorepx dim kid as single 定義學號 dim rowend as single 定義結束行號 dim rowrecord as single 定義新序列插入位...

5用SQL命令查詢所有學生的學號 姓名 總成績 平均成績

你的表是 來什麼名?表源 裡有哪些欄位?假如你的學bai生表是dustudent,學號的欄位名是 學號 姓zhi名dao的欄位名是 姓名 成績的欄位名是 成績 那麼查詢所有學生的學號就是 select 學號,姓名,evg 成績 sum 成績 from student 應該就是這樣的了你執行一下試試 ...

有學生表 編號,姓名,班級 ,成績表 學生編號,科目編號,成績 sql查詢學生編號,姓名,科目成績,沒成績的為

浙江省義烏市義亭鎮中 姓名黃婷婷 qq號碼 手機號碼 是指 的意思嗎?感覺沒弄懂 存在班級表 班級,學生編號 和學生資訊表 學生編號,學生姓名,學歷 用sql語句查詢每個班級學歷為 table class class id stu no table student stu no stu name s...