Answered by:
crm 2011 - Relationship Design question

Question
-
Hi All,
We are in the process of designing the real estate solution for our company and are having difficulty to achive following.
Scenario:
1. We are using in-built Account -to-Opportunity relationship to track our customers with opportunity.
2. We have 1 custom entity called "Premises". (Actual property in real estate term having Account and other fields like start and end date etc...)
3. 'Premises' have 1-N relationship with opportunity.
4. 'Premises' have 1-N relationship with Account.
Now, in the opportunity form, we want to show all the premises where their account is same as their opportunity account(in subgrid).
So, in SQL statement term we want following
Select all premises where opportunity.account = premises.account
Is there anyway we can achieve above and showing result in opportunity form subgrid. We are flexible to change our Account and Opportunity entity relationship with 'premises' entity.
Thanks,
Kane
Monday, August 6, 2012 12:16 AM
Answers
-
You need to pass the filter to fetchxml in JavaScript.
Have a look at this
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer". Amreek Singh Senior CRM Consultant CDC Praxa Sydney, Australia http://mscrmshop.blogspot.com http://crm2011usersettings.codeplex.com
- Proposed as answer by Amreek Singh Monday, August 6, 2012 5:23 AM
- Marked as answer by CRM Thirsty Monday, August 6, 2012 10:42 PM
Monday, August 6, 2012 5:22 AM
All replies
-
Hey buddy,
I think you have your relationship wrong.
if there is 1:N relationship between premises and account then there will only be 1 premise attached to the account.
anyway if its other way around yes it is achievable.
I hope this helps.
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer". Amreek Singh Senior CRM Consultant CDC Praxa Sydney, Australia http://mscrmshop.blogspot.com http://crm2011usersettings.codeplex.com
Monday, August 6, 2012 3:21 AM -
Hi Amreek,
Apologies..You spotted it correctly. It's other way around but I still don't know how can i set up the subgird on the opportunity form where
I can show all premises which account is same as of premises account.
Thanks for your response.
Monday, August 6, 2012 4:31 AM -
You need to pass the filter to fetchxml in JavaScript.
Have a look at this
If you find this post helpful then please "Vote as Helpful" and "Mark As Answer". Amreek Singh Senior CRM Consultant CDC Praxa Sydney, Australia http://mscrmshop.blogspot.com http://crm2011usersettings.codeplex.com
- Proposed as answer by Amreek Singh Monday, August 6, 2012 5:23 AM
- Marked as answer by CRM Thirsty Monday, August 6, 2012 10:42 PM
Monday, August 6, 2012 5:22 AM -
Hi Amreek,
Thanks for showing the right direction
Feeling dumb for not searcing on internet or SDK properly :(
Cheers !!
- Edited by CRM Thirsty Monday, August 6, 2012 10:45 PM
Monday, August 6, 2012 10:44 PM