You can translate the question and the replies:

Gathering data for all dates in a range

Hello! I am looking to create a backfill of data for dates where I can say give me all the data for a specific day and append it to each other so I have a table like 1/1/21 data data data 1/2/21 data data data ... And then have the ability to add new lines to it as we go into the future. In SQL I just use a while loop which I understand is not possible here, but I am not able to find good documentation on how I can do this in Denodo in a stored procedure or anywhere else. Thanks!
user
21-03-2023 14:20:00 -0400
code

1 Answer

Greetings, Hope you are doing well. In Denodo, information can be queried instantly once you have properly set the data sources. And such queries are ad-hoc, that is you could apply different filters as needed. When you want to force the user to apply a specific filter condition whenever data is being retrieved, view parameters can be set. For instance, a selection view can be created to always query data within a date range using start_date and end_date as mandatory input parameters. More information about view parameters can be found [here](https://community.denodo.com/docs/html/browse/8.0/en/vdp/administration/creating_derived_views/creating_selection_views/creating_selection_views). As you have mentioned, a stored procedure can be developed to simplify the process of retrieving required data. Denodo supports the development of stored procedures in [**VQL**](https://community.denodo.com/docs/html/browse/8.0/en/vdp/developer/developing_extensions/developing_stored_procedures/developing_vql_stored_procedures) (stored procedures that make use of conditions and loops; however, Denodo Enterprise or Denodo Enterprise Plus is needed. See also [Denodo Platform - Subscription Bundles](https://https://community.denodo.com/docs/html/browse/8.0/en/platform/installation/appendix/denodo_platform_feature_packs/denodo_platform_feature_packs#denodo-platform-subscription-bundles)) and [**Java**](https://community.denodo.com/docs/html/browse/8.0/en/vdp/developer/developing_extensions/developing_stored_procedures/developing_stored_procedures). More information on executing developed stored procedures can be found [here](https://community.denodo.com/docs/html/browse/8.0/en/vdp/administration/stored_procedures/stored_procedures). Relevant references and examples can be found below: [Stored procedure using datetime values](https://community.denodo.com/docs/html/browse/8.0/en/vdp/developer/developing_extensions/developing_stored_procedures/using_datetime_values_in_denodo_stored_procedures) [Sorted procedures in creating new view ](https://community.denodo.com/docs/html/browse/8.0/en/vdp/administration/stored_procedures/use_of_stored_procedures_in_creating_views/use_of_stored_procedures_in_creating_views) [Using Denodo4E custom extension ](https://community.denodo.com/tutorials/browse/customcomponents/1denodo4e) Moreover, in regard to creating data loads on a regular basis, this can be typically implemented using Denodo’s scheduler component where for instance you could automate the execution of a view. For more details, kindly check below references: [VQL Guide - Stored Procedures](https://community.denodo.com/docs/html/browse/8.0/en/vdp/vql/stored_procedures/stored_procedures) [VDP Admin Guide – Stored procedures](https://community.denodo.com/docs/html/browse/8.0/en/vdp/administration/stored_procedures/stored_procedures) [Denodo Scheduler Guide](https://community.denodo.com/docs/html/browse/8.0/en/scheduler/administration/introduction/introduction) Hope this helps!
Denodo Team
23-03-2023 09:13:20 -0400
code
You must sign in to add an answer. If you do not have an account, you can register here