Dev 401-003:Application Essential:Building Your Data Model

Object Relationships
1.Link two objects
- Parent to child
- One to Many
2.Two main Types:
- Look up
- Master- Detail
3.Two special types:
- Self
- Many to many

Lookkup Relationships
1.Loosely coupled
- Child field value may be optional
- No cascade delete
- Independent ownership & sharing
2. Maximum 25 look-up relationships per child

Master-Detail Relationships
1.Tightly coupled
- child field value is always required
- Cascade delete
- Inherited ownership & sharing
2.Maximum 2 master relationships per detail object

Let's Compare... Look-up and Master-detail Relationships
Look-up Relationships                     Master Relationships
Up to 25 allowed per object              Up to 2 allowed per object
Parent is not a required field           Parent filed on child is required
No impact on security and access         Access to parent determines access to children
Can be multiple layers deep            Can only be one layer deep(a child of one master-detail relationship cannot be the parent of another)
Look-up field is not required              Look-up field on page layout is required
Both relationship types look almost the same on a page layout:both include a look-up field for the one side and related list for the many side.

Relationships and Reporting
Relation Type RelationTypeStandard Report TypesReport Type Category
LookupObject by itselt object with first lookupBased on the object
Object with second lookup
Object with third lookup
Master-DetalObject by itselt object with first lookupMaster object
Object with second lookup
Object with third lookup
Many-To-ManyPrimary master object by itself Secondary       Primary master object and
master object by itselfSecondary master object
Primary master object with junction
Object and secondary master object
Secondary master object with junction
object and primary master object

Exercise 2-3:Creating lookup Relationships
1.Goal:
- Create lookup relationships to connect objects to one another.
2.Scenario:
- Universal Containers needs to be able to see which Job Applications are related to each Position. Additionally, they need 
to see which Hiring Managers are related to each Position.
3.Tasks:
- Create a lookup relationship between Job Application and Position
- Create a lookup relationship between Position and Hiring Manager.

Self Relationships
1.A self relationship is a lookup relationship to the same object.
- Example: it is possible to create a lookup relationship from Position to Position
2. the User object has a special type of lookup relationship:the hierarchy relationship.For example, a hierarchy 
relationship allows developers to create a manager field on the User object to relate another user.

Many-to-many Relationships
1.Allow for the relationship of two object in a many-to-many fashion
- Candidates may apply for many position by submitting a job application fro each position
- A position may have many candidates apply.
- Implementing a many-to-many relation requires a third junction object.

Junction Objects
1.When modeling a many-to-many relation, you use a junction object to connect the two objects you want to relate to each 
other.
2.A junction object is a custom object with two master-detail relationships.
3.When  creating a junction object, consider the following:
- Name the object with a label that indicates its purpose.
- Use the auto-number data type.

Exercise 2-5:Creating a Custom Junction Object.
1.Goal:
- Create a Many-to-Many Relationship between Position and Job Posting Site.
2.Scenario:
- Universal Containers will have many positions advertised on various job posting sites. They want to be able to connect and 
manage those records within Salesforce.
3.Tasks:
- Create a new custom junction object.
- Create the master-detail relationships of Job Posting with Position and Job Posting Site.

Module Review
1.What is a custom object?
2.List examples of custom field types.
3.True or false:if a field is set to "universally required," users will be required to populate it when loading data 
through the API.
4.List the for types of custom relationships that can be built in the force.com platform and describe the differences 
between them.

Building Applications with Force.com and VisualForce (DEV401) (三):Application Essential:Building Your Data Model的更多相关文章

  1. Building Applications with Force.com and VisualForce (DEV401) (二) : Application Essentials:Designing Application on the Force.com Platform

    Dev 401-002:Application Essentials:Designing Application on the Force.com Platform Course Objectives ...

  2. Building Applications with Force.com and VisualForce (DEV401) (四):Building Your user Interface

    Dev 401-004:Application essential:Building Your user Interface: Module Agenda1.Custom Applications2. ...

  3. Building Applications with Force.com and VisualForce(Dev401)(十):Designing Applications for Multiple Users: Building Business Processes that You Want

    Dev401-011: Building Business Processes that You Want Course Objectives1.Describe the capabilities o ...

  4. Building Applications with Force.com and VisualForce(Dev401)(十八):Visualforce Pages: Introduction to Visualforce

    Dev401-020:Visualforce Pages: Introduction to Visualforce Course Objectives1.Understand the benefits ...

  5. Building Applications with Force.com and VisualForce (DEV401) (二十):Visualforce Pages: Visualforce Componets (Tags)

    Dev401-021:Visualforce Pages: Visualforce Componets (Tags) Module Agenda1.Tag Basics2.Tag Bindings T ...

  6. Building Applications with Force.com and VisualForce(Dev401)(十九):Visualforce Pages: Visualforce Componets (Tags)

    Dev401-020:Visualforce Pages: Visualforce Componets (Tags) Module Agenda1.Tag Basics2.Tag Bindings T ...

  7. Building Applications with Force.com and VisualForce(Dev401)(七):Designing Applications for Multiple users:Managing your users' experience I

    Dev 401-007 Designing Applications for Multiple users: Managing your users' experience part 1 Module ...

  8. Building Applications with Force.com and VisualForce (DEV401) (二五):Visualforce Controller

    Dev401-026:Visualforce Pages: Visualforce Controller   Module Objectives1.Identify the functionality ...

  9. Building Applications with Force.com and VisualForce (DEV401) (二一):Visualforce Componets (Tags) Library Part 1

    Dev401-022:Visualforce Pages: Visualforce Componets (Tags) Library Part 1 Module Objectives1.List ke ...

随机推荐

  1. 理解 Java 内存模型的因果性约束

    目录 理解 Java 内存模型的因果性约束 欢迎讨论 规范理解 例子练习 例子1 例子2 总结 理解 Java 内存模型的因果性约束 欢迎讨论 欢迎加入技术交流群186233599讨论交流,也欢迎关注 ...

  2. 等效燃油消耗ECMS与庞德里亚金最小值原理PMP中协同状态的关系

    今儿阅读了一篇文献——<车联网环境下并联混合动力客车控制策略优化研究>,是北理的博士所写的,内容比较翔实.主要是里面的关于ECMS和庞德里亚金最小值原理(PMP)的关系推导很让人印象深刻, ...

  3. MYSQL对数据库和表的基本操作

    CREATE DATABASE testdb CHARSET=UTF8 创建一个数据库 名字叫做testdb USE testdb; 选择数据库 CREATE TABLE testTable1( ) ...

  4. shell 之 case。。。esac多分支选择

    case分支属于匹配执行的方式,它针对指定的变量预先设置一个可能的取值,判断该变量的实际取值是否与预设的某一个值相匹配,如果匹配上了,就执行相应的一组操作,如果没有任何值能够匹配,就执行预先设置的默认 ...

  5. springboot框架中集成thymeleaf引擎,使用form表单提交数据,debug结果后台获取不到数据

    springboot框架中集成thymeleaf引擎,使用form表单提交数据,debug结果后台获取不到数据 表单html: <form class="form-horizontal ...

  6. OCR场景文本识别:文字检测+文字识别

    一. 应用背景 OCR(Optical Character Recognition)文字识别技术的应用领域主要包括:证件识别.车牌识别.智慧医疗.pdf文档转换为Word.拍照识别.截图识别.网络图片 ...

  7. 必备技能一、webpack

    https://cloud.tencent.com/developer/section/1477376----->配置很重要 一.基本安装 mkdir webpack-demo &&am ...

  8. json中存整形数值,前端返回为空

    实现目标: 在servlet中将整型数值转为json,然后在前端获取 问题描述: 前端获取为空,显示为:console.log打印为:{} 解决办法: 在servlet中将数值转为json格式再进行传 ...

  9. 实验一 Linux系统与应用准备(嵌入式Linux工程师的“修真之路”)

    作业格式 项目 内容 这个作业属于哪个课程 这里是链接[https://edu.cnblogs.com/campus/nchu/2020SpringSystemAndApplication] 这个作业 ...

  10. 在AX中解析多层的json信息

        str jsonstr ='{"FieldValues":[{"FieldName":"Field1","FieldVal ...