In order to isolate the reason for the performance hit on the cached view, I would suggest taking a look at the Execution Trace of your query when run from Tableau versus when run within the VQL Shell. You should be able to catch it while executing via the [Query Manager](https://community.denodo.com/docs/html/browse/6.0/vdp/administration/installation_and_execution/launching_the_virtual_dataport_administration_tool/query_monitor) and compare the Execution Plan to the trace when you run it within Denodo. Alternately, you can inspect the [Request Monitor](https://community.denodo.com/docs/html/browse/6.0/vdp/dmt/monitoring/monitoring_servers/monitoring_requests) of the Diagnostic and Monitoring Tool if you have it set up to see all completed requests and their Execution Plan.
If you are running the same *exact* query against the view in both applications, the plan should be the same, but variables such as the type of underlying data sources and whether the fields involved in your SELECT DISTINCT clause are indexed could come in to play. If there is a difference, it will probably depend on the specifics of the cache settings as to whether you are using a full or partial cache, the time-to-live of the cache, and for partial cache if it is matching 'exact queries only'. If the Plan is the same and you are confident that you are using the most logical cache strategy for the data sources involved in this view, I would take a look at the RDBMS you are using for the cache database and its connection parameters to ensure it is not becoming a bottleneck for the cache process given the large quantity of records in your derived view.
See the Connection tab section of [Configuring the Cache](https://community.denodo.com/docs/html/browse/6.0/vdp/administration/server_administration_-_configuring_the_server/configuring_the_cache/configuring_the_cache) if you need more details on configuring the connection to your cache RDBMS, and the documentation on the [Cache Module](https://community.denodo.com/docs/html/browse/6.0/vdp/administration/cache_module/cache_module) for more information on how to choose the best cache strategy - or if caching is even necessary - based on your data source and querying needs.
Hope this helps!