RE: Can I create a view of records (from a custom entity) which do NOT have any upcoming/scheduled activities?
Hi,
Thank you for your query.
As far as I know, you cannot achieve this using OOB features.
This means you cannot apply a filter in the views to get results based on NOT IN operator.
For example, you can list Accounts where Activity Start Date is in the Next 1 month, however, you cannot list Only Accounts where Activities Start Date NOT IN NEXT 7 DAYS.
To achieve this, I would suggest the following approaches:
- Add a Roll-up field (whole number) to store the count of Activities where is status is Scheduled (or Open):
![pastedimage1613067403041v1.png](/api/data/v9.1/msdyn_richtextfiles%287F4130D5-0F25-4C2B-899D-12ABFAF6C5E5%29/msdyn_imageblob/$value?size=full)
Then use this count in your views (chart), however, the rollup fields are not updated instantly and you cannot apply filters like 'Start date is in Next 1 month'.
- Create a whole number filed (simple) and use a plugin to get a count of the open (scheduled) activities. You can register the plugin on creating/update of Activity where regarding is your custom entity. Implement all your conditions and update the count to be used in views.
- If you are using on-premise, you can write an SQL Server query and use it in the SSRS report.