ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / HFSQL / HFSQL Client/Server functions
  • When are rights changed?
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Modifies the rights granted to a user or to a group for a HFSQL Client/Server database.
Remark: to find out the rights granted to a group or to a user on an HFSQL Client/Server database, use HInfoDatabaseRights.
Example
// Copy the rights from one user to another
sRights is string
sRights = HInfoDatabaseRights(MyConnection, "Moore", hRightsRead + hRightsInsert, "MyDatabase")
HModifyDatabaseRights(MyConnection, "Moore", hRightsRead + hRightsInsert, sRights, "MyDatabase")
Syntax
<Result> = HModifyDatabaseRights(<Connection> , <User or group> , <Rights to modify> , <New values> , <Database>)
<Result>: Boolean
  • True if the 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.
Remark: HErrorInfo will return "Unknown user" or "Unknown group" if the current user tries to access information about a specific user or group but does not have enough permissions (hRightsSeeUser constant).
<Connection>: Character string or Connection variable
Connection for which the rights granted to a user or group of users should be modified. This connection corresponds to:
<User or group>: Character string
Name of the user or group whose rights should be modified.
<Rights to modify>: Integer constant (or combination of constants)
List of rights to modify:
hRightsAutoModifRights to perform the automatic modification of data files on a data file.
hRightsBackupRights to perform a backup.
hRightsChangeLinkRights to modify the integrity rules on a data file.
hRightsChangeOwnerRights to modify the owner of an element.
hRightsChangeRightsRights to change rights.
hRightsConnectionRights to connect to a server (encrypted or unencrypted connection).
hRightsCreateFileRights to create a data file (with HCreation).
hRightsCreateViewRights to create an SQL view or a materialized view.
hRightsDebugRights to debug the stored procedures.
hRightsDeleteRights to delete the records from a data file.
hRightsDeleteDBRights to delete a database.
hRightsDeleteFileRights to delete a data file (HDeleteFile).
hRightsDeleteViewRights to delete a view.
hRightsEncryptedConnectionRights to connect to a server (encrypted connection only).
hRightsInsertRights to add new records into a data file.
hRightsLockRights to lock the data files or the records of a data file.
hRightsMaintenanceRights to start a re-index operation or to perform statistical calculations on a data file.
hRightsManageDuplicateRights to enable and disable the management of duplicates.
hRightsManageIntegrityRights to enable and disable the management of integrity.
hRightsManageProcedureRights to add, modify and delete the sets of procedures.
hRightsManageTriggerRights to add, enable and delete server triggers.
hRightsNoDatabaseAccessRights to prevent access to a database (HNoDatabaseAccess and HEndNoDatabaseAccess).
hRightsReadRights to read the records of a data file.
hRightsRunProcedureRights to run a stored procedure.
hRightsUnmaskRights to unmask items in the database files.
hRightsUpdateRights to modify the records of a data file.
<New values>: Integer constants
Lists the 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 user will inherit the right granted to the group to which they belong.
<Database>: Character string
Name of the database for which the rights should be modified.
Remarks

When are rights changed?

Rights are modified when HModifyDatabaseRights is run. There is no need to restart the server to apply the new rights.
Managing duplicates and integrity: The error does not occur when the management mode is modified but when an attempt is made not to comply with the integrity constraint (or with the duplicate constraint).
Component: wd300hf.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
METODO CREATE DATABASE HFSQL CLIENT/SERVER VIA WEBSERVICE COM DIRETIVAS OK
https://forum.pcsoft.fr/fr-FR/pcsoft.br.windev/3252-informatica-novo-metodo-create-database-hfsql-client-server/read.awp
BOLLER
13 Jul. 2019

Last update: 06/14/2024

Send a report | Local help