7/7今日接續Admin Beginner系列,學習第二個module:Data Modeling。
(*學習筆記主要是記錄挑戰操作的部分,以及一些重要資訊)
Data Model:It’s a way to model what database tables look like in a way that makes sense to humans.
- 資料庫表格(對象): objects,可創建自定義custom object。
- 表格的欄: fields,可創建自定義custom field。
每個field都有自己的 data type,像是Checkbox、Date、DateTime、Formula。自定義field的field name colum會顯示XXX__c,"__c"表示特定field是自定義field。
- 表格的列: records
(一) Challenge1:Build a custom Offer object
Create a custom object:
- 進到Setup裡的Object Manager,按Create->Customer Object。
2. 依照題目要求輸入資訊,按Save。
3. 成功新稱Object — Offer。
Create a custom currency field on the Offer object:
- 在Offer Object裡按Fields&Relationships,再按New。
2. Data Type選Currency->Next。
3. 依照題目要求輸入資訊,按Next->Next->Save。
Create a custom date field on the Offer object:步驟同上。
*註:Create a Record:在Sales App裡找到Obect,按New新增一筆record。
(二) Challenge2:Create relationships for the Offer object
- Lookup Relationships:the relationship between the two objects.(相互獨立的)
- Master-Detail Relationships:one object is the master and another is the detail.(有高相關性,若其一被刪除,另一個也須被刪除)
- Hierarchical Relationship:hierarchical relationships are a special type of lookup relationship. The main difference between the two is that hierarchical relationships are only available on the User object.
Create a custom Lookup field on the Offer object:
- 在Offer Obect的Fields&Relationships裡->New,選擇Lookup Relationship->Next->Next->Next->Save。
Create a custom Master-Detail field on the Offer object:步驟同上。
(三) Challenge3:Use Schema Builder to create a custom field for the Property object
- 按Clear All,選擇Favorite、Property、Offer。
2. 新增一個field到Property Object,從Elements拖拉Text Area到Property。
3. 依照題目要求輸入資訊。
這個module完成啦~~~操作起來蠻直覺簡單的!明天繼續下一個吧!
若有任何問題或錯誤的地方歡迎留言~
離開之前記得給點掌聲喔👏