AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Ayuda / WLanguage / Administrar bases de datos / HFSQL / Funciones HFSQL Client/Server
  • When are rights changed?
WINDEV
WindowsLinuxJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac Catalyst
Otros
Procedimientos almacenados
<Connection variable>.ModifyViewRights (Función)
HFSQL Client/ServerDisponible solo con este tipo de conexión
Sets the rights granted to a user or group on an SQL view or on a materialized view.
Remark: It is possible to find out the rights of a group or a user on a SQL view or on a materialized view using the <Connection variable>.InfoViewRights function.
Ejemplo
// Description de la connexion
MaConnexion is Connection

// Copie des droits d'un utilisateur à un autre 
sDroits is string
sDroits = MaConnexion.InfoDroitVue("Dupont", ...
	hRightsRead + hRightsInsert, "MaBase", "MaVueClient")
MaConnexion.ModifieDroitVue("Durand", ...
	hRightsRead + hRightsInsert, sDroits, "MaBase", "MaVueClient")
Sintaxis
<Result> = <Connection>.ModifyViewRights(<User/Group> , <Rights to modify> , <New values> , <Database> , <View>)
<Result>: Booleano
  • True if rights have been modified,
  • False otherwise. HErrorInfo is used to identify the error.
No modification is performed if the new value is already assigned to the specified rights.
Note: An "Unknown User" or "Unknown Group" error will be returned by the HErrorInfo function if the current user does not have the user viewing right (constant hDroitVisualisationUtilisateur) and is requesting information about another user or group.
<Connection>: Variable de tipo Connection
Name of the Connection variable that describes the connection for which the rights of a user or group of users must be modified.
<User/Group>: Cadena de caracteres
Name of the user or group whose rights should be modified.
<Rights to modify>: Constante o combinación de constantes de tipo Integer
List of rights to modify:
hRightsChangeRightsRights to change rights.
hRightsDeleteRights to delete records from a view.
hRightsDeleteViewRights to delete a view.
hRightsInsertRights to add records to a view.
hRightsMaintenanceRights to start a reindex operation or a statistical calculation on a materialized view.
hRightsReadRights to read the records of a view.
hRightsUpdateRights to modify the records of a view.
<New values>: Constantes de tipo Integer
List of new values for the modified rights. New values must be assigned to all the rights specified in <Rights to modify> (in the same order).
If a single value is indicated in this parameter, it will be assigned to all the rights specified in <Rights to modify>.
The possible values are as follows:
hAllowedThe relevant rights are granted to the user or group.
hForbiddenThe relevant rights are not granted to the user or group.
hInheritThe right is undefined at this level for the user (or the group to which they belong). The HFSQL server uses the right defined at the top level for the user (or the group to which the user belongs). For a view, the HFSQL server uses the right defined for the user (or the group to which the user belongs) at database level.
<Database>: Cadena de caracteres
Name of the database containing the SQL view or the materialized view for which the rights must be modified.
  • If the database corresponds to the one defined in the connection, this parameter can correspond to an empty string ("").
  • A WLanguage error occurs if no database is defined in the connection and if this parameter corresponds to an empty string.
<View>: Cadena de caracteres
Name of the SQL view or materialized view for which the rights must be modified.
Observaciones

When are rights changed?

Rights are modified when <Connection variable>.ModifyViewRights is run. There is no need to restart the server to apply the new rights.
Componente: wd300hf.dll
Versión mínima requerida
  • Versión 25
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 25/02/2025

Señalar un error o enviar una sugerencia | Ayuda local