iT邦幫忙

0

第38天~畫完圖來看語法

Tzu 2022-02-08 22:18:19862 瀏覽
  • 分享至 

  • xImage
  •  

這篇的上一篇:https://ithelp.ithome.com.tw/articles/10283918

畫完圖來看語法

https://ithelp.ithome.com.tw/upload/images/20220208/20119035ZXsaspxwkE.png

出現錯誤不用理

https://ithelp.ithome.com.tw/upload/images/20220208/20119035yX9SEdL0e0.png

跑出語法-按COPY
https://ithelp.ithome.com.tw/upload/images/20220208/20119035Jek8Mquayw.png

回到MSSQL-資料庫-按"新增查詢"-執行
https://ithelp.ithome.com.tw/upload/images/20220208/20119035kTUHlJQoR5.png

再來查看

https://ithelp.ithome.com.tw/upload/images/20220208/20119035NTUi3vBztB.png

按重新整理-就可以看到-一對多

https://ithelp.ithome.com.tw/upload/images/20220208/201190350Vi5sxmTmk.png

長這樣
https://ithelp.ithome.com.tw/upload/images/20220208/20119035yhWxnBPa3n.png

再到~資料庫圖表-新增資料庫圖表
https://ithelp.ithome.com.tw/upload/images/20220208/20119035Pu6kidq9eQ.png
選課程+測驗-排好
https://ithelp.ithome.com.tw/upload/images/20220208/20119035TVwrhum28I.png

試著在課程加入資料-

https://ithelp.ithome.com.tw/upload/images/20220208/20119035ApGGwmgT9e.png

課程編號打1001

https://ithelp.ithome.com.tw/upload/images/20220208/201190358YVHvtXx4E.png
試著在測驗加入資料-課程編號一定要打1001--外來鍵才可以查到

https://ithelp.ithome.com.tw/upload/images/20220208/20119035R5cPICVaiW.png

參考關聯性


希望最後可以來練習一下t-sql join as語法~~


這篇的下一篇:https://ithelp.ithome.com.tw/articles/10283960


圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言