Deals Under the Holding Company
Advanced SolvedGlobex runs its regional businesses as child accounts under a holding company account. The group CFO wants every deal booked by those regional accounts.
Return each Opportunity's Name and its account's name (Account.Name) where the account's parent account is named Globex Holdings.
Sample data
Account 5 records
| Name | Parent |
|---|---|
| Globex Holdings | null |
| Initech Group | null |
| Globex India | Globex Holdings |
| Globex Japan | Globex Holdings |
| Initech Labs | Initech Group |
Opportunity 4 records
| Name | StageName | Amount | CloseDate | Account |
|---|---|---|---|---|
| India renewal | Prospecting | 40,000 | today + 30 days | Globex India |
| Japan pilot | Qualification | 25,000 | today + 30 days | Globex Japan |
| Labs upgrade | Prospecting | 18,000 | today + 30 days | Initech Labs |
| Holding direct | Prospecting | 90,000 | today + 30 days | Globex Holdings |
Expected result on the sample
| Name | Account.Name |
|---|---|
| India renewal | Globex India |
| Japan pilot | Globex Japan |
Row order does not matter. Only the columns above are compared; extra columns in your SELECT are fine.
Hints
- An Account's parent account is
Parent. - From Opportunity:
Account.Parent.Name.
What this tests
Dot notation can climb more than one level: Account.Parent.Name goes from the deal to its account and then to that account's parent, up to five levels. Filtering on the account name instead catches the holding company's own deals and misses regional accounts with different names.
Datasets
Solved on this device only. Sign in with Google to keep your progress across devices.
Run on sample executes your query against the sample data shown on the left and displays the rows it returns. Submit checks it against the sample plus 2 hidden datasets, comparing your rows with the expected rows on each. Queries run in a real Salesforce org; the data is inserted for your run and rolled back afterwards.