Execute in the database engine the sentence "SET LOCK MODE TO NOT WAIT [segs]".
Optionally it can be indicated the number of seconds of the waiting time.
1 connection.setLockModeToNotWait
<connection.setLockModeToNotWait time='time'/>
Attributes | |||||
---|---|---|---|---|---|
Name | Type | Required | Default | Description | |
Atime | int |
|
Returns | |
---|---|
Type | Description |
Integer | If specified, the number of seconds of wait. |
Example
Execute the instruction before making a query. This is useful when there is another running process that can block the table, in this way, it is indicated that before the consultation is made, a time is waited until the blockade ends.
Copy
<xsql-script name='test_con'> <body> <connection.setLockModeToNotWait time='180' /> <foreach> <select prefix='m_'> <columns> c1 </columns> <from table='tab1'/ > </select> <do> <println><m_c1/></println> </do> </foreach> </body> </xsql-script>