题目内容

创建数据库表,下列语句中正确的是()。

A. create table stu(no integer, name text, sex text, age integer)
B. table stu(no integer, name text, sex text, age integer)
C. create stu(no integer, name text, sex text, age integer)
D. 以上都不对

查看答案
更多问题

向stu表中插入数据(1,’张三’,’男’,18),以下插入操作正确的是()。

A. insert stu (1,’张三’,’男’,18)
B. insert into stu as (1,’张三’,’男’,18)
C. insert into stu values(1,’张三’,’男’,18)
D. 以上都不对

将stu表中学号(no)为1的记录的年龄增加2岁,下列操作正确的是()。

A. update stu age=age+2 where no=1
B. update stu age=age+2 no=1
C. update stu set age=age+2 where no=1
D. update stu set age=age+2 no=1

下列哪项不是connection对象的常用方法()。

A. commit()
B. cursor()
C. rollback()
D. fetchone()

下列哪项不是cursor对象的常用方法()。

A. execute()
B. fetchone()
C. close()
D. commit()

答案查题题库