前一篇说了sql语句的数据库操作,这一篇就说下表的操作。
1:先说下表的插入,更新,删除这些操作。
a:插入 insert
规正式的插入:/* insert into tablename(column) values(?) */
/* column也可以没有,可以是一张表,没有值的列用null补齐 */
insert into student(sid,sname) values(1,'1'...
分类:
数据库 时间:
2015-03-03 18:44:46
阅读次数:
173
1.创建数据库create database test ;2. 创建表create table student (id int , name char(8) , sex char(4));—创建了一个student表,有id name sex 三个字段3. 查看数据表字段select columns...
分类:
数据库 时间:
2015-03-02 23:48:47
阅读次数:
228
create database testgouse testgocreate table student( --学号 sno varchar(3) not null primary key, --姓名 sname varchar(4) not null, --性别 ...
分类:
数据库 时间:
2015-03-02 20:53:41
阅读次数:
254
#include#include#includeusing namespace std;struct Student{ int GE,GI,sum,rank,ID; int prefer[6];}STU[40066];struct School{ int want; //各学校招...
分类:
其他好文 时间:
2015-03-02 18:20:07
阅读次数:
170
#include#include#includeusing namespace std;int want[106]; //各学校招生人数struct Student{ int GE,GI,sum,rank,ID; int prefer[6]; bool R; /...
分类:
其他好文 时间:
2015-03-02 16:22:37
阅读次数:
195
#include#includeusing namespace std;struct Student{ char name[15]; char ID[15]; int gread;}STU[66666];bool cmp(Student a,Student b){ return a.grea...
分类:
其他好文 时间:
2015-03-02 12:55:55
阅读次数:
179
#include#include#includeusing namespace std;struct Student{ int ID; int score[6]; int perfect; int sum; int rank;}S[10066];int p[6]; //1-5存题号1...
分类:
其他好文 时间:
2015-03-02 12:46:57
阅读次数:
188
#include#include#includeusing namespace std;struct Student{ char ID[10]; char name[10]; int gread;}STU[100010];bool cmp1(Student a,Student b){ ret...
分类:
其他好文 时间:
2015-03-01 20:56:07
阅读次数:
204
// 创建对象// Person *student = [[Person alloc]init];// // student->_hobby = @"玉兔";// [student sayHi];// [student sleep]; // Person *caoyu = [[Person...
分类:
其他好文 时间:
2015-03-01 17:03:07
阅读次数:
183
---比较特殊,第一次看到这种写法,记录下来create table Student --学生成绩表( id int, --主键 Grade int, --班级 Score int --分数)INSERT INTO Student VALUES(1,1,88),(2,1,66),(3,1,75).....
分类:
其他好文 时间:
2015-03-01 16:58:10
阅读次数:
140