您的位置 电脑知识爱好者 >> 编程知识 >> 数据库课程设计报告和设计实例

数据库课程设计报告和设计实例

电脑知识爱好者http://www.l9l8.com本站整理2007-6-20 14:35:11
知识重点:数据库课程设计报告和设计实例 sql数据库课程设计 数据库课程设计实例vid 自动编号 username 用户(varchar) filepath 文件路径(varchar) filename 文件名(varchar) addtime 时间(smalldatetim..
[/font][font=宋体]窗口([/font][font=Times New Roman]w_scoreinput[/font][font=宋体])[/font][/size]
[font=Times New Roman][size=3]Open[/size][/font][font=宋体][size=3]事件代码:[/size][/font]
[font=Times New Roman][size=3]    dw_1.SetTransObject(SQLCA)
dw_1.Retrieve()
[/size][/font][size=3][font=宋体]控件[/font][font=Times New Roman]datawindow[/font][font=宋体]的[/font][font=Times New Roman]dataobject[/font][font=宋体]属性:[/font][font=Times New Roman]i_score [/font][font=宋体](一个[/font][font=Times New Roman]freeform[/font][font=宋体]风格的数据窗口对象,显示[/font][font=Times New Roman]exam[/font][font=宋体]表的全部列)[/font][/size]
[font=Times New Roman][size=3]commandbutton[/size][/font][size=3][font=宋体]([/font][font=Times New Roman]text[/font][font=宋体]属性:保存)[/font][font=Times New Roman]clicked[/font][font=宋体]事件的代码:[/font][/size][size=3][font=Times New Roman]dw_1.Update()
commandbutton[/font][font=宋体]([/font][font=Times New Roman]text[/font][font=宋体]属性:取消)[/font][font=Times New Roman]clicked[/font][font=宋体]事件的代码:[/font][/size][size=3][font=Times New Roman]dw_1.Retrieve()
commandbutton[/font][font=宋体]([/font][font=Times New Roman]text[/font][font=宋体]属性:插入)[/font][font=Times New Roman]clicked[/font][font=宋体]事件的代码:[/font][/size][size=3][font=Times New Roman]dw_1.InsertRow(dw_1.GetRow())
commandbutton[/font][font=宋体]([/font][font=Times New Roman]text[/font][font=宋体]属性:删除)[/font][font=Times New Roman]clicked[/font][font=宋体]事件的代码:[/font][/size][size=3][font=Times New Roman]dw_1.DeleteRow(dw_1.GetRow())

 

[/font][font=宋体]窗口([/font][font=Times New Roman]w_query[/font][font=宋体])[/font][/size][size=3][font=宋体]控件[/font][font=Times New Roman]statictext[/font][font=宋体]的[/font][font=Times New Roman]text[/font][font=宋体]属性:[/font][font=Times New Roman]“[/font][font=宋体]请输入学号:[/font][/size][size=3][font=Times New Roman]”
[/font][font=宋体]控件[/font][font=Times New Roman]groupbox[/font][font=宋体]包含[/font][font=Times New Roman]24[/font][font=宋体]个[/font][font=Times New Roman]statictext[/font][font=宋体]控件,它们的[/font][font=Times New Roman]text[/font][font=宋体]属性分别对应[/font][font=Times New Roman]info[/font][font=宋体]表的字段名和查询结果[/font][/size][size=3][font=宋体]控件[/font][font=Times New Roman]SingleLineEdit[/font][font=宋体]的[/font][font=Times New Roman]text[/font][font=宋体]属性为[/font][/size][size=3][font=Times New Roman]null
commandbutton[/font][font=宋体]([/font][font=Times New Roman]text[/font][font=宋体]属性:查询)[/font][font=Times New Roman]clicked[/font][font=宋体]事件的代码:[/font][/size]
[font=Times New Roman][size=3]Connect;
if SQLCA.SQLCode<0 then
    MessageBox("[/size][/font][font=宋体][size=3]连接错误[/size][/font][size=3][font=Times New Roman]",SQLCA.SQLErrText,Exclamation!)
end if
//MessageBox("done",SQLCA.SQLErrText,Exclamation!)
int     Stu_id
string  Stu_name,Stu_xuehao,Stu_sex,Stu_age,Stu_home
string  Stu_birth,Stu_depart,Stu_price,Stu_info,Stu_health
Stu_id=Integer(sle_id.Text)

select info.sno,info.sname,info.sex,info.age,
        info.depart,info.prize,info.exp,info.home,
        info.health,info.grade,info.class,info.other
       
        Into :Stu_sno,:Stu_sname,:Stu_sex,:Stu_age,
                :Stu_depart,:Stu_prize, :Stu_exp,:Stu_home,
                :Stu_health,:Stu_grade:Stu_class, :Stu_other
        From student Where info.sno=:Stu_id;
               

参与评论
相关内容
关于我们 | 隐私政策 | 站点地图 | 站长博客|京ICP备07025396号
添加到百度搜藏 添加到百度搜藏 电脑知识爱好者Copyright ?2006-2008版权所有 我要啦免费统计