PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Properties specific to the link description
  • How to describe the data files by programming?
  • Handling the links of a data file described by programming
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Link description (Type of variable)
In French: Description de liaison (Type de variable)
HFSQLHFSQL Client/ServerAvailable only with these kinds of connection
A Link description variable is used to describe a link between two data files by programming. The description of each link is validated by HDescribeLink.
After this validation:
  • This link can be handled like any other link described in the analysis.
  • The "Link description" variable is reinitialized and it can be used to describe another link by programming.
Versions 17 and later
iPhone/iPad This type of variable is now available for the iPhone and iPad applications.
New in version 17
iPhone/iPad This type of variable is now available for the iPhone and iPad applications.
iPhone/iPad This type of variable is now available for the iPhone and iPad applications.
Versions 18 and later
Universal Windows 10 App This type of variable is now available in Windows Store apps mode.
New in version 18
Universal Windows 10 App This type of variable is now available in Windows Store apps mode.
Universal Windows 10 App This type of variable is now available in Windows Store apps mode.
Versions 21 and later
Universal Windows 10 App This type of variable is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This type of variable is now available in Universal Windows 10 App mode.
Universal Windows 10 App This type of variable is now available in Universal Windows 10 App mode.
Note: From version 19, HFSQL is the new name of HyperFileSQL.
Example
MyLink is Link Description
MyLink1, MyLink2 are Link Descriptions
// Describe and validate the City and Customer files
...

// Describe the "LIVES" link
MyLink..Name = "LIVES"
MyLink..SourceFile = "CITY"
MyLink..LinkedFile = "CUSTOMER"
MyLink..SourceKey = "CITYNAME"
MyLink..LinkedKey = "CUSTCITY"
// Default link (0-1, 0-1)

// Validate the description of the "LIVES" link
HDescribeLink(MyLink)
Syntax

Declaring one or more link descriptions Hide the details

<Variable Name> is Link Description
<Variable Name 1>, <Variable Name 2> are Link Descriptions
<Variable Name>:
Name of the "Link description" variable to declare.
Note: The a and an keywords are optional: they provide better readability.

Describing a "Link description" variable Hide the details

To describe a "Link description" variable:
Use the WLanguage properties specific to the link descriptions. See remarks for more details.

To validate the description of a "Link Description" variable:
Use HDescribeLink.
Remarks

Properties specific to the link description

The following properties are specific to the link descriptions:
Note: The properties written in bold followed by a star must necessarily be initialized when a link is described by programming.
Property nameEffect
MaxLinkedCardinalityMaximum cardinality of the linked item in a link
MinLinkedCardinalityMinimum cardinality of the linked item in a link
MaxSourceCardinalityMaximum cardinality of the source item in a link
MinSourceCardinalityMinimum cardinality of the source item in a link
LinkedKey ( * )Item of the linked file used in the link
SourceKey ( * )Item of source file used in the link
LinkedFile ( * )Name of the linked file used in the link
SourceFile ( * )Name of the source file used in the link
Name ( * )Name of the link
ModificationRuleModification rule (integrity management) used in a link
DeletionRuleDeletion rule (integrity management) used in a link
By default, the cardinalities of the link are (0-1) / (0-1).

How to describe the data files by programming?

To describe the data files by programming, you must:
1. Declare the "File description", "Item description", "FullTextIndex description" and "Link description" variables (if necessary).
2. For each data file:
3. Describe (if necessary) the characteristics of links via the HFSQL properties.
4. Validate (if necessary) the description of each link (HDescribeLink.

Handling the links of a data file described by programming

When a link is created in the data model editor, the name of the link is automatically recognized by the compiler.
When creating a link via a "Link description" variable, the name of this link is defined by ..Name. This name is not automatically recognized by the compiler. Using this name to identify the link generates a compilation error.
In order for the name of the link created by programming to be recognized by the compiler, this name must be declared via the Extern keyword. This link can now be handled by its name in the code editor.
For example:
MyLink is Link Description
...
MyLink..Name = "LIVES"
...
HDescribeLink("LIVES")
...
EXTERN LIVES
...
Cardinality = LIVES..MaxLinkedCardinality
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment