Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - Programming » Three-Tier Computing and Distributed Transactions » Using EAServer with SQL Anywhere

Configuring EAServer Next Page

Setting the component transaction attribute


In EAServer you can implement a component that carries out operations on more than one database. You assign a transaction attribute to this component that defines how it participates in transactions. The transaction attribute can have the following values:

For example, in the Sybase Virtual University sample application, included with EAServer as the SVU package, the SVUEnrollment component enroll method carries out two separate operations (reserves a seat in a course, bills the student for the course). These two operations need to be treated as a single transaction.

Microsoft Transaction Server provides the same set of attribute values.

To set the transaction attribute of a component
  1. In Jaguar Manager, locate the component.

    To find the SVUEnrollment component in the Jaguar sample application, connect to the Jaguar server, open the Packages folder, and open the SVU package. The components in the package are listed in the right pane.

  2. Set the transaction attribute for the desired component.

    Right-click the component, and choose Component Properties from the popup menu. Click the Transaction tab, and choose the transaction attribute value from the list. Click OK to complete the operation.

    The SVUEnrollment component is already marked as Requires Transaction.

  3. Once the component transaction attribute is set, you can perform SQL Anywhere database operations from that component, and be assured of transaction processing at the level you have specified.