PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Handling records during a transaction
  • Transactions and independent HFSQL context
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
Allows you to find out whether a transaction was interrupted (the transaction was neither validated nor canceled). The characteristics of the interrupted transaction are returned by the HFSQL variables.
We advise you to call this function in the initialization code of project. If the transaction is interrupted, you can:
  • HFSQL start WDTRANS or WDOptimizer.
  • HFSQL Client/Server start the HFSQL Control Center.
  • cancel the transaction by programming.
HFSQL Client/Server This function is useful when transactions have been interrupted on password-protected data files.
Versions 17 and later
iPhone/iPad This function is now available for the iPhone/iPad applications.
New in version 17
iPhone/iPad This function is now available for the iPhone/iPad applications.
iPhone/iPad This function is now available for the iPhone/iPad applications.
Versions 18 and later
Universal Windows 10 App This function is now available in Windows Store apps mode.
New in version 18
Universal Windows 10 App This function is now available in Windows Store apps mode.
Universal Windows 10 App This function is now available in Windows Store apps mode.
AndroidAndroid Widget iPhone/iPadWindows Mobile The management of transactions is available for the HFSQL Client/Server databases.
Versions 20 and later
Java This function is now available for the Java applications.
Android This function is now available for the Android applications.
Android Widget This function is now available in Android Widget mode.
New in version 20
Java This function is now available for the Java applications.
Android This function is now available for the Android applications.
Android Widget This function is now available in Android Widget mode.
Java This function is now available for the Java applications.
Android This function is now available for the Android applications.
Android Widget This function is now available in Android Widget mode.
Note: From version 19, HFSQL is the new name of HyperFileSQL.
Versions 21 and later
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Example
IF HTransactionInterrupted("") = True THEN
        HTransactionCancel()
END
Syntax
<Result> = HTransactionInterrupted([<Name of Transaction File>])
<Result>: Boolean
  • True if a transaction was interrupted,
  • False if no transaction was interrupted. The following HFSQL variables are updated:
    H.TrsInternalIDValue if the transaction was interrupted: Internal number used to identify the transaction.
    Value if the transaction was not interrupted: -1
    H.TrsPostValue if the transaction was interrupted: Identifier defined by HPost or name of computer from which the transaction was started.
    Value if the transaction was not interrupted: Empty string ("")
    H.TrsMachineNameValue if the transaction was interrupted: Name and IP address of client computer.
    Value if the transaction was not interrupted: Empty string ("").
    Note: This variable is available in HFSQL Client/Server mode only.
    H.TrsApplicationNameValue if the transaction was interrupted: Application name in the following format: Executable Name(Project Name).
    Value if the transaction was not interrupted: Empty string ("").
    Note: This variable is available in HFSQL Client/Server mode only.
<Name of Transaction File>: Optional character string (with quotes)
Full name of transaction file (used to store the operations performed in transaction). This file is automatically destroyed when using HTransactionEnd or HTransactionCancel.
If this name corresponds to an empty string ("") or if it is not specified, the transaction file used is the default transaction file (in the directory of the application named: <Project Name>_$TRS_OPERATION.trs).
HFSQL Client/Server This parameter is ignored by the Client/Server transactions, it is only taken into account by the HFSQL Classic transactions.
Remarks

Handling records during a transaction

During a transaction, some rules must be complied with when handling the records. See Transactions: Handling records during a transaction for more details.

Transactions and independent HFSQL context

When copying a context, if a transaction is in progress on the first context, the new context is not in transaction. You must call HTransactionStart to start a transaction in the new context.When copying a context, if a transaction is in progress on the first context, the new context is not in transaction. You must call HTransactionStart (or HTransaction) to start a transaction in the new context.
Components
WINDEVWEBDEV - Server codeReports and Queries wd230hf.dll
Windows Mobile wp230hf.dll
Java wd230java.jar
Linux wd230hf.so
Android wd230android.jar
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment