DatabaseSync Class
Provides access to databases via the WebSQLDatabase API. Only the synchronous part of the API is implemented because asynchronous code is usually not required for server-side scripting. Accessed from system.getDatabaseSync function (using the 'system' global variable).
Methods
changeVersion
()
Not implemented.
readTransaction
-
[callback]
Run the read transaction contained in the given callback function. A SQLTransactionSync object is passed as an argument to the callback. This may be used execute queries. The transaction is committed if the callback returns normally and rolled back if it throws an exception.
Parameters:
-
[callback]
Function optionalcallback function
-
[transaction]
SQLTransactionSync optionalTransaction object which can be used to execute SQL queries.
-
transaction
-
[callback]
Run the non-read transaction contained in the given callback function. A SQLTransactionSync object is passed as an argument to the callback. This may be used execute queries. The transaction is committed if the callback returns normally and rolled back if it throws an exception.
Parameters:
-
[callback]
Function optionalcallback function
-
[transaction]
SQLTransactionSync optionalTransaction object which can be used to execute SQL queries.
-
Properties
lastRowIdQuery
String
The ID of the most recently inserted row.
version
Notimplemented
Not implemented.