You can translate the question and the replies:

List of Roles and complete hierarchy

How do i get the list of roles in Denodo and the complete role hierarchy?
user
30-05-2019 02:08:31 -0400

5 Answers

Hi, I was able to get the list of all the role and the role hierarchy in the Denodo Platform by executing the following commands in VQL shell 1. ** List roles**: This command will give you a list of all the roles which are present in the Denodo Platform. 1. ** Desc role <ROLE_NAME>**: This command will give the hierarchy of the roles in the Denodo Platform. For more information, you can refer to the section[ Listing Elements in the Catalog ](https://community.denodo.com/docs/html/browse/7.0/vdp/vql/listing_elements_in_the_catalog/listing_elements_in_the_catalog#listing-elements-in-the-catalog) and[ Output Schema of the DESC Commands](https://community.denodo.com/docs/html/browse/7.0/vdp/developer/appendix/output_schema_of_the_desc_commands/output_schema_of_the_desc_commands#output-schema-of-the-desc-commands) of the Virtual DataPort Developer Guide. Hope this helps!
Denodo Team
30-05-2019 05:55:22 -0400
Thanks, however is there any other option to get the entire role hierarchy at once rather than for each role ?
user
21-06-2019 07:41:45 -0400
Hi, You can get the list of all roles and their corresponding hierarchies by going through the following steps in the Virtual DataPort Administration Tool: 1. Create new JDBC type data source and select Denodo Virtual DataPort as the Database adaptor and provide the necessary details, test the connection. 1. Create a **base view A **using ‘Create from query’ option using the list roles query mentioned in the above comment. 1. Create another **base view B** using the ‘Create from query’ option and provide the following query: Desc role @varible_name where the **@variable_name** is interpolation variable. 1. Set the Delegate SQL Sentence as Sub Query option to no in the search methods -> option-> wrapper source configurations of both the base views. 1. Create the join between the** name** field of **base view A **and the interpolation variable of **base view B**. Execute this view to get the expected results. For more information, you can refer to Using the [Create Base View From Query](https://community.denodo.com/kb/view/document/Using%20the%20Create%20Base%20View%20From%20Query%20Option?category=Data+Sources) Option Knowledge Base article. Hope this Helps!
Denodo Team
02-07-2019 08:24:56 -0400
I was trying to create a view using 'List Roles;' using ‘Create from query’ but got the following error. Finished with error: Error executing query. Total time 0.985 seconds. BV_LIST_ROLES [BASE] [ERROR] BV_LIST_ROLES [JDBC WRAPPER] [ERROR] BV_LIST_ROLES#0 [JDBC ROUTE] [ERROR] Received exception with message 'Syntax error: Exception parsing query near 't0'' The VDP datasource works well and I can create other views from it. The o/p of 'List Roles;' as I can see in the VQL shell is not a table. Maybe this is causing the issue? Please provide if there is any exclusive documentation on this.
user
02-06-2020 06:57:57 -0400
Hi, In order to resolve the 'Syntax error: Exception parsing query near 't0'' error, I would perform the following: * Open "bv_list_roles" base view and navigate to "**Options>Search Methods > wrapper source configuration**" section. * Set the property ["Delegate SQL Sentence as Sub Query"](https://community.denodo.com/docs/html/browse/7.0/vdp/administration/creating_derived_views/advanced_configuration_of_views/view_configuration_properties#view-configuration-properties) as "**No**". Once this is done, I could execute the view successfully. For more information, you could refer to the [Using the Create Base View From Query Option](https://community.denodo.com/kb/view/document/Using%20the%20Create%20Base%20View%20From%20Query%20Option?category=Data+Sources) Knowledge Base Article. Hope this helps!
Denodo Team
16-06-2020 05:43:07 -0400
You must sign in to add an answer. If you do not have an account, you can register here