ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / Managing databases / HFSQL / Managing triggers / WLanguage functions
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
HDeactivateTrigger (Function)
In french: HDésactiveTrigger
ODBCNot available with this kind of connection
Disables a trigger. Then, this trigger can be re-enabled by HActivateTrigger.
Reminder A trigger is a WLanguage procedure automatically called by the HFSQL engine each time an HFSQL function is executed. A trigger is defined by HDescribeTrigger. For more details, see Trigger management.
Example
// Dans le code d'initialisation du projet
LOCAL
	ResultatTrigger is boolean
// Création du Trigger pour tous les fichiers de données de l'analyse
ResultatTrigger = HDescribeTrigger("*", "HAJOUTE,HMODIFIE," + ...
		"HSUPPRIME,HRAYE,HECRIT", "VerifDroitUtilisateur", hTriggerBefore)
// Avec "VerifDroitUtilisateur" une procédure globale du projet
IF ResultatTrigger = False THEN
	Error("Erreur sur un trigger : " + HErrorInfo)
	RETURN
END
...
// Désactive le trigger pour tous les fichiers de données
// Sur les fonctions HSupprime et HRaye
HDeactivateTrigger("*", "HSUPPRIME,HRAYE")
Syntax
<Result> = HDeactivateTrigger([<List of data files> [, <List of functions>]] [, <Type>])
<Result>: Boolean
  • True if the operation was performed,
  • False if a problem occurs. HError is used to identify the error.
<List of data files>: Optional character string
Logical name of one or more data files.
To specify several names of data files, the names of the data files must be separated by a comma (",").
To use all the data files found in the analysis, this parameter must be equal to "*".

By default, all the data files are taken into account.
<List of functions>: Optional character string
Name of one or more HFSQL or TableXXX functions on which the trigger must be implemented. To specify several names of functions, the names of functions must be separated by a comma (","). You have the ability to define triggers on the following HFSQL functions:If <List of functions> is set to "*", all the HFSQL functions that can activate a trigger are taken into account.

By default, all the HFSQL functions that can activate a trigger are taken into account.
<Type>: Optional Integer constant
Indicates the type of trigger. All triggers are affected if this parameter is not specified.
hTriggerAfterThe procedure is run after the HFSQL function.
hTriggerBeforeThe procedure is run before the HFSQL function.
Business / UI classification: Business Logic
Component: wd300hf.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 03/28/2025

Send a report | Local help