JoltRollback Function

Action

Performs the transaction rollback for a JoltTransaction object.

Include file

Jolt.bdh

Syntax

JoltRollback( in hTransaction : number ):boolean;

Return value

  • true if successful

  • false otherwise

Parameter Description
hTransaction Handle to a JoltTransaction object that was created with JoltTransactionNew

Example

var
  hSession, hSessionAttr, hTransaction: number;
 dcltrans
  transaction TInit
  begin
     JavaSetOption(JAVA_VERSION, JAVA_V11);
     JavaSetOption(JAVA_HOME, "c:/jdk1.1.7");
     JavaSetOption(JAVA_CLASSPATH, "c:/jdk1.1.7");
     JoltInit();
     hSessionAttr := JoltSessionAttributesNew();
    JoltSetString(hSessionAttr, APPADDRESS, "//lab:8000");
    hSession := JoltSessionNew(hSessionAttr, "", "ATM", "", "");
  end TInit;
  transaction TMain
  begin
    hTransaction := JoltTransactionNew(0, hSession);
    ...
    JoltRollback(hTransaction);
  end TMain; 

  transaction TShutdown
  begin
    JoltEndSession(hSession);
    JoltFreeObject(hTransaction);
    JoltFreeObject(hSession);
    JoltFreeObject(hSessionAttr);
  end TShutdown;

See also

Java: bea.jolt.JoltTransaction class