| 1 |
<?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| 2 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 3 |
<html xmlns="http://www.w3.org/1999/xhtml"> |
| 4 |
<head> |
| 5 |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
| 6 |
<title>Enabling Transaction Snapshots in the SQL Layer</title> |
| 7 |
<link rel="stylesheet" href="gettingStarted.css" type="text/css" /> |
| 8 |
<meta name="generator" content="DocBook XSL Stylesheets V1.73.2" /> |
| 9 |
<link rel="start" href="index.html" title="Berkeley DB Installation and Build Guide" /> |
| 10 |
<link rel="up" href="upgrade_52_toc.html" title="Chapter 10. Upgrading Berkeley DB 11.2.5.1 applications to Berkeley DB 11.2.5.2" /> |
| 11 |
<link rel="prev" href="upgrade_11gr2_52_heap.html" title="Heap Access Method" /> |
| 12 |
<link rel="next" href="upgrade_11gr2_52_rep_2site_strict.html" title="2SITE_STRICT Enabled by Default in Replication" /> |
| 13 |
</head> |
| 14 |
<body> |
| 15 |
<div xmlns="" class="navheader"> |
| 16 |
<div class="libver"> |
| 17 |
<p>Library Version 11.2.5.3</p> |
| 18 |
</div> |
| 19 |
<table width="100%" summary="Navigation header"> |
| 20 |
<tr> |
| 21 |
<th colspan="3" align="center">Enabling Transaction Snapshots in the SQL Layer</th> |
| 22 |
</tr> |
| 23 |
<tr> |
| 24 |
<td width="20%" align="left"><a accesskey="p" href="upgrade_11gr2_52_heap.html">Prev</a> </td> |
| 25 |
<th width="60%" align="center">Chapter 10. |
| 26 |
Upgrading Berkeley DB 11.2.5.1 applications to Berkeley DB 11.2.5.2 |
| 27 |
</th> |
| 28 |
<td width="20%" align="right"> <a accesskey="n" href="upgrade_11gr2_52_rep_2site_strict.html">Next</a></td> |
| 29 |
</tr> |
| 30 |
</table> |
| 31 |
<hr /> |
| 32 |
</div> |
| 33 |
<div class="sect1" lang="en" xml:lang="en"> |
| 34 |
<div class="titlepage"> |
| 35 |
<div> |
| 36 |
<div> |
| 37 |
<h2 class="title" style="clear: both"><a id="upgrade_11gr2_52_mvcc_sql"></a>Enabling Transaction Snapshots in the SQL Layer</h2> |
| 38 |
</div> |
| 39 |
</div> |
| 40 |
</div> |
| 41 |
<div class="toc"> |
| 42 |
<dl> |
| 43 |
<dt> |
| 44 |
<span class="sect2"> |
| 45 |
<a href="upgrade_11gr2_52_mvcc_sql.html#idp951464">New Pragmas</a> |
| 46 |
</span> |
| 47 |
</dt> |
| 48 |
</dl> |
| 49 |
</div> |
| 50 |
<p> |
| 51 |
Read/write concurrency can now be enabled in the SQL API by using |
| 52 |
<code class="literal">PRAGMA multiversion=on</code> before accessing any |
| 53 |
tables in the database. After multiversion has been enabled, it |
| 54 |
can be temporarily disabled using the |
| 55 |
<code class="literal">PRAGMA transaction_snapshots=on/off</code>. |
| 56 |
</p> |
| 57 |
<div class="sect2" lang="en" xml:lang="en"> |
| 58 |
<div class="titlepage"> |
| 59 |
<div> |
| 60 |
<div> |
| 61 |
<h3 class="title"><a id="idp951464"></a>New Pragmas</h3> |
| 62 |
</div> |
| 63 |
</div> |
| 64 |
</div> |
| 65 |
<p> |
| 66 |
For more details on pragmas concerning Transaction Snapshots |
| 67 |
read <a href="../bdb-sql/mvcc.html" class="olink">Using Multiversion Concurrency Control</a> in the <em class="citetitle">Berkeley DB Getting Started with the SQL APIs</em> guide. |
| 68 |
</p> |
| 69 |
<div class="itemizedlist"> |
| 70 |
<ul type="disc"> |
| 71 |
<li> |
| 72 |
<code class="literal">PRAGMA multiversion=ON|OFF;</code> |
| 73 |
</li> |
| 74 |
<li> |
| 75 |
<code class="literal">PRAGMA snapshot_isolation=ON|OFF</code> |
| 76 |
</li> |
| 77 |
</ul> |
| 78 |
</div> |
| 79 |
</div> |
| 80 |
</div> |
| 81 |
<div class="navfooter"> |
| 82 |
<hr /> |
| 83 |
<table width="100%" summary="Navigation footer"> |
| 84 |
<tr> |
| 85 |
<td width="40%" align="left"><a accesskey="p" href="upgrade_11gr2_52_heap.html">Prev</a> </td> |
| 86 |
<td width="20%" align="center"> |
| 87 |
<a accesskey="u" href="upgrade_52_toc.html">Up</a> |
| 88 |
</td> |
| 89 |
<td width="40%" align="right"> <a accesskey="n" href="upgrade_11gr2_52_rep_2site_strict.html">Next</a></td> |
| 90 |
</tr> |
| 91 |
<tr> |
| 92 |
<td width="40%" align="left" valign="top">Heap Access Method </td> |
| 93 |
<td width="20%" align="center"> |
| 94 |
<a accesskey="h" href="index.html">Home</a> |
| 95 |
</td> |
| 96 |
<td width="40%" align="right" valign="top"> 2SITE_STRICT Enabled by Default in Replication</td> |
| 97 |
</tr> |
| 98 |
</table> |
| 99 |
</div> |
| 100 |
</body> |
| 101 |
</html> |