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
  • The same trigger is applied to several files or to several WLanguage functions
  • Compatibility with the earlier versions
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
HListTrigger (Function)
In french: HListeTrigger
Returns the list of triggers applied to one or more HFSQL data files.

Reminder A trigger is a WLanguage procedure called automatically each time one or more HFSQL functions are executed. For more details, see Trigger management
Example
// Récupérer les triggers appliqués sur les fichiers de données Client et Produit
ListeTriggers is string
ListeTriggers = HListTrigger("Client,Produit")

// Ajoute la liste des triggers dans la combo COMBO_COMBO1
ListAdd(COMBO_COMBO1, ListeTriggers)
Syntax
<Result> = HListTrigger([<Name of data file(s)>])
<Result>: Character string
List of triggers applied to the specified data files. The different triggers are separated by CR characters (Carriage Return).
The list has the following format:

<Data file> + TAB + <WLanguage procedure> + TAB +
<HFSQL function> + TAB + <Type of trigger> +
TAB + <Trigger status> + CR +...
<Data file>Name of the data file to which the trigger applies.
<HFSQL function>HFSQL function onto which the trigger applied.
<Trigger status>
<Type of trigger>
  • "A" for a "BEFORE" trigger (the procedure associated with the trigger is run before the HFSQL function of trigger).
  • "P" for an "AFTER" trigger (the procedure associated with the trigger is run after the HFSQL function of trigger).
<WLanguage procedure>Name of the WLanguage procedure called by the trigger.
<Name of data file(s)>: Optional character string
Name of one or more data files. If this parameter is not specified, the triggers of all the data files found in the analysis associated with the current project will be listed.
To specify several names, the names of the data files must be separated by a comma (",").
Remarks
HFSQL ClassicHFSQL Client/ServerNative Connectors (Native Accesses)

The same trigger is applied to several files or to several WLanguage functions

If a trigger (described by HDescribeTrigger) is applied to several data files or to several WLanguage functions, this trigger will be displayed several times in the list (according to the number of HFSQL functions and/or data files).
Example 1: a trigger is applied to several data files:
// Décrit un trigger appliqué sur les fichiers de données Client et Produit
HDescribeTrigger("Client,Produit", "HAjoute", "VerifParam", hTriggerBefore)
MaListe is string = HListTrigger()

// Le contenu de MaListe sera le suivant :
// Client  <TAB>  VerifParam  <TAB>  HAjoute  <TAB>  A  <TAB>  1
// Produit  <TAB>  VerifParam  <TAB>  HAjoute  <TAB>  A  <TAB>  1
Example 2: a trigger is applied to several HFSQL functions:
// Décrit un trigger appliqué sur les fonctions HAjoute et HModifie
HDescribeTrigger("CLIENT", "HAjoute,HModifie", "VerifParam", hTriggerAfter)
MaListe is string = HListTrigger()
// Le contenu de MaListe est le suivant :
// CLIENT  <TAB>  VerifParam  <TAB>  HAjoute  <TAB>  P  <TAB>  1
// CLIENT  <TAB>  VerifParam  <TAB>  HModifie <TAB>  P  <TAB>  1

Compatibility with the earlier versions

The following syntax is kept for backward compatibility:
<Result> = HListTrigger([<File name> [,<Full WDD name>]])
The <Full WDD name> parameter is kept for backward compatibility. This parameter is ignored.
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/27/2025

Send a report | Local help