Hi!
You are correct that Denodo does not support automatically delegating ‘LIMIT’ to Hive. The only way to have the ‘LIMIT’ be delegated would be the ‘Create base view from query’ option. If I understand your situation correctly, you want to be able to have the limit be delegated when running queries on the base view but want the ability to not have the number of rows limited when running queries on views that are built on top of the base view.
Assuming you are using an interpolation variable in your base view, this functionality is easily achievable. When executing your base view, you can specify at runtime whichever limit you wish. Now, let’s say you create a derived view on top of your base view, and you do not want the limit to be utilized when executing this view. When creating this derived view, in the ‘Where Conditions’ tab set the value of the interpolation variable to be larger than the total number of tuples in the original base view. The ‘LIMIT’ will still be delegated, but its value will be too high to filter out any tuples. This will allow you to use the limit to filter out tuples when querying the base view, but not filter out tuples when querying a derived view built on top of that base view.
If you decide to use this option, you’ll likely want to enable ‘Delegate SQL Sentence as Subquery.’ By doing this, VDP will be able to delegate more queries over the base view to the database. This option can be found in the Wrapper Source Configuration window of the advanced tab for your view.
You can find more information about creating a base view from SQL query in the ‘Creating JDBC/ODBC Base Views from SQL Queries’ section of the VDP Admin Guide
One thing to note is that ‘LIMIT’ is not the only option for restricting the number of tuples. Alternatively, you may want to simply utilize where conditions when executing your query rather than applying a limit. For example, if your view has an ‘id’ column, you could query it with the condition ‘WHERE id < 1000’ or something similar. This provides another means of restricting the number of tuples returned by your base view and could help to optimize your performance.
Hope that helps!