PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Using space characters in the parameters
  • Describing an index
  • Limitations
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
HDBDescribeIndex (Function)
In French: HDBDecritIndex
Native AccessesHFSQLAvailable only with these kinds of connection
Describes by programming the different index files that will be created. An index file must be described for each search key. The created index file will be in dBase 3 format.
Note: The data file and the index files will be created by HDBCreation (in dBase 3 format only). Therefore, the indexes with a format other than NDX cannot be created by HDBDescribeIndex.
Note: From version 19, HFSQL is the new name of HyperFileSQL.
Example
HDBDescribeFile("CUSTOMER", "DA", "C:\FILE\CUSTOMER.DBF")
HDBDescribeField("LASTNAME,C,20")
HDBDescribeField("FIRSTNAME,C,20")
HDBDescribeField("MARRIED,L")
HDBDescribeField("DOB,D")
HDBDescribeField("INFO,M")
HDBDescribeIndex("C:\FILE\LASTNFILE.NDX", "LASTNAME")
HDBDescribeIndex("C:\FILE\LNFNFILE.NDX", "FULLNAME,C,40", "LASTNAME+FIRSTNAME")
HDBCreation()
Syntax
<Result> = HDBDescribeIndex(<Full Name of Index File> , <Name of Key Item> , <Expression of Composite Key>)
<Result>: Boolean
  • True if the operation was performed,
  • False if a problem occurred. HError is used to identify the error.
<Full Name of Index File>: Character string (with quotes)
Access path to index file and full file name (with the extension)
<Name of Key Item>: Character string (with quotes)
  • Name of simple key: this name corresponds to the name of a file item.
  • Name and type of composite key. <Name of Key Item> has the following format "<Name_CompKey>,<KeyType>":
    <Name_CompKey>Name of composite key
    <KeyType>Type of key:
    • C,<Size>: Text item, <Size> is the size of character string
    • N,<Size>,<NbDecimals>: Numeric item. <Size> is the size of numeric value, <NbDecimals> is the number of decimals in the numeric value.
    • L: Boolean item.
    • D: Date item (in "YYMMDD" format).
    • M: Text Memo item.
<Expression of Composite Key>: Character string (with quotes)
Expression of composite key to use.
Remarks

Using space characters in the parameters

The parameters must not be separated by space characters; for example, you must not write:
HDBDescribeIndex("C:\FILE\LNFNFILE.NDX", "FULLNAME, C, 40", "LASTNAME+FIRSTNAME")
You must write:
HDBDescribeIndex("C:\FILE\LNFNFILE.NDX", "FULLNAME,C,40", "LASTNAME+FIRSTNAME")

Describing an index

  • An error 1009 will be generated if the file is already opened during the call to HDBDescribeIndex.
  • The maximum size of an item:
    • cannot exceed 254 characters for a non-key text item.
    • cannot exceed 100 characters for a key text item.
    • cannot exceed 19 digits in the integer part and 15 digits in the decimal part for a numeric item.
  • To use HDBDescribeIndex, the file must be described by HDBDescribeFile.

Limitations

  • This function is not available when accessing a database via Remote Access.
  • This function is not available when using a stand-alone executable.
Components
WINDEVWEBDEV - Server codeReports and Queries wd230hf.dll
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment