第11讲1--初始嵌入式SQL.pdf
![资源得分’ title=](/images/score_1.gif)
![资源得分’ title=](/images/score_1.gif)
![资源得分’ title=](/images/score_1.gif)
![资源得分’ title=](/images/score_1.gif)
![资源得分’ title=](/images/score_05.gif)
《第11讲1--初始嵌入式SQL.pdf》由会员分享,可在线阅读,更多相关《第11讲1--初始嵌入式SQL.pdf(20页珍藏版)》请在淘文阁 - 分享文档赚钱的网站上搜索。
1、? An Introduction to Database System? ? ? ? ? ? ? An Introduction to Database System SQL? ?SQL? ? ? 1? 2? An Introduction to Database System ?SQL? ?SQL? 1 ?SQL 2 ?SQL? ? ? ?SQL 3 ? ?ODBC? An Introduction to Database System ?11?SQL ? ?4?8.1? An Introduction to Database System Video 11-1?SQL An Introd
2、uction to Database System ?SQL #include #include EXEC SQL BEGIN DECLARE SECTION; /*? */ char HSno9; char HSname20; char HSex2; int HSage; char Hdept20; EXEC SQL END DECLARE SECTION; /*? */ long SQLCODE; EXEC SQL INCLUDE sqlca; /*?SQL? */ int main() /*c? */ printf(Please input the sno:);/*? */ scanf(
3、%s, HSno); /* ?TEST?localhost? ?54321?SYSTEM/krms? */ EXEC SQL CONNECT TO TESTlocalhost:54321 AS CONN1 USER SYSTEM“ USING “manager; EXEC SQL SELECT Sno,Sname,Ssex,Sage,Sdept INTO:Hsno,:Hname,:Hsex,:Hage,:Hdept FROM Student WHERE Sno=:HSno; if (sqlca.sqlcode = 0) printf(n% - 9s% - 20s% - 2s% - 4s% -
4、20sn, Sno, Sname, Ssex, Sage, Sdept); printf(% - 9s% - 20s% - 2s% - 4s% - 20sn, Hsno, Hname, Hsex, HSage, Hdept); EXEC SQL DISCONNECT CONN1; return 0; An Introduction to Database System ?SQL? ? ?SQL?SQL? ? ? ?EXEC SQL? ?C? ? EXEC SQL ; ? ?EXEC SQL SELECT Sno,Sname,Ssex,Sage,Sdept INTO:Hsno,:Hname,:H
5、sex,:Hage,:Hdept FROM Student WHERE Sno=:givensno; An Introduction to Database System ?SQL? ? SQL? ? ? ? ? ? ? ? ?SQL ? ? ? ? ? ? ? ? (? ?SQL) ? ? ? ? ? ? ? An Introduction to Database System ? ? ? ?SQL? ? ? ? ? An Introduction to Database System 1 ? EXEC SQL CONNECT TO target AS connection-name USE
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 11 初始 嵌入式 SQL
![提示](https://www.taowenge.com/images/bang_tan.gif)
限制150内