You can translate the question and the replies:

Finding a folder in GET_VIEWS() with a partial name

Hi all, How do I find a view in a folder based on a partial name of the folder? For example: SELECT name FROM GET_VIEWS WHERE input_database_name = 'database' AND folder='/%derived%' Some of my databases have views stored in say: 1. Derived Views 2. Derived Views 3. Derived Views etc. So if I wanted to find the views for all derived views folders, I might not know what number they are stored in and would like a blanket search statement. Thanks!
user
15-12-2021 12:16:01 -0500

1 Answer

Hi, In order to retrieve all the derived views from all the folders with the requirements below: * Providing the partial name of the folder in the where condition. * Using generic search instead of mentioning the folder number. I could specify the** "where"** condition for the folder column with the **'like'** operator in the **"GET_VIEWS"** predefined stored procedure as mentioned in the below example: ``` select name from GET_VIEWS() where folder like '%derived%' ``` By executing the above query, I was able to retrieve all the derived views from all the folders in the Virtual DataPort Administration Tool. For more information about the like operator and the GET_VIEWS stored procedure, you can take a look at the [Comparison Operators](https://community.denodo.com/docs/html/browse/latest/en/vdp/vql/language_for_defining_and_processing_data_vql/comparison_operators/comparison_operators#comparison-operators), [GET_VIEWS](https://community.denodo.com/docs/html/browse/8.0/en/vdp/vql/stored_procedures/predefined_stored_procedures/get_views#get-views) sections in the Virtual DataPort VQL Guide. Hope this helps!!
Denodo Team
16-12-2021 08:04:05 -0500
You must sign in to add an answer. If you do not have an account, you can register here