Saving Recordsets as XML
SECTION 12 Databases
196
modifications to data in a connection, regardless of the Recordset. A
transaction is started by calling DBExecute with the 'BeginTrans' command.
From that point, any request to add, modify or delete records are stored
instead of being immediately processed. The Transaction is completed either
by calling DBExecute with the 'CommitTrans' command, which processes all
the stored requests in one go, or by calling DBExecute with the
'RollbackTrans' command, which discards all the stored requests leaving the
database as it was when the Transaction started.
12-7-1 Nested Transactions
Transactions may be nested, that is a new transaction may be started before
the preceding transaction has been completed. In this case, any
'CommitTrans' or 'RollbackTrans' commands relate to the most recently
started transaction, and any further 'CommitTrans or 'RollbackTrans'
commands relate to the transaction begun before it.
12-8
Saving Recordsets as XML
Using the DBExecute() 'Save' command any Recordset may be saved as an
XML file, to be imported in to another application. XML resembles and
complements HTML. XML describes data, such as city name, temperature
and barometric pressure, and HTML defines tags that describe how the data
should be displayed, such as with a bulleted list or a table. XML, however,
allows developers to define an unlimited set of tags, bringing great flexibility to
authors, who can decide which data to use and determine its appropriate
standard or custom tags.
Example: XML is used to describe an Employees phone list:
<EmployeeList>
<Entry>
<Employee>John Jones</Employee>
<Phone>555-1213</Phone>
<Type>Mobile</Type>
</Entry>
<Entry>
<Employee>Sally Mae</Employee>
<Phone>555-1217</Phone>
<Type>Business Fax</Type>
</Entry>
</EmployeeList>
You can use an application with a built in XML parser, such as Microsoft®
Internet Explorer 5 to view XML documents in the browser just as you would
view HTML pages.
Note:
Care should be taken to ensure that each 'BeginTrans' is matched with a
'CommitTrans' or 'RollbackTrans' to ensure that your work is saved or
discarded as required. If there are any pending transactions when a
connection is closed, the user will be prompted to either commit or rollback
these outstanding transactions. A DBExecute command 'TransCount' is
available which returns the number of pending transactions.
Note:
Not all Providers support use of Transactions.
Содержание CX-Supervisor
Страница 1: ...CX Supervisor Software Cat No W10E EN 01 User Manual Software Release 3 1...
Страница 3: ...Copyright Notice 2...
Страница 16: ...15...
Страница 17: ...16...
Страница 27: ...Tip of the Day SECTION 1 Graphics Editor 26...
Страница 35: ...CX Supervisor Preferences SECTION 2 Pages 34...
Страница 79: ...Responding to Events SECTION 5 ActiveX Objects 78...
Страница 115: ...Printing the Graphics Library SECTION 7 Graphics Library 114...
Страница 181: ...Data Logging SECTION 11 Data Logging 180...
Страница 201: ...Examples SECTION 12 Databases 200...
Страница 243: ...Performance Monitor SECTION 16 Application Analysis Performance Monitor 242...
Страница 253: ...Using with Omron s CX Server OPC SECTION 17 Using CX Supervisor as an OPC Cli 252...
Страница 259: ...Creating a CX Supervisor Client application SECTION 18 Connecting to a remote CX 258...
Страница 263: ...Adding a Point Linked to a Parameter SECTION 19 Connecting to Omron Industrial 262...
Страница 271: ...Data Logging SECTION 20 Best Practices 270...
Страница 275: ...Configuring a Server PC running Windows NT or 2000 Appendix A Configuring a PC 274...
Страница 277: ...Appendix B Frequently Asked Questions 276...
Страница 296: ...Appendix B Frequently Asked Questions 295...
Страница 297: ...Appendix B Frequently Asked Questions 296...
Страница 298: ...Appendix B Frequently Asked Questions 297...
Страница 299: ...Appendix B Frequently Asked Questions 298...
Страница 333: ...Revision history 332...