/usr/share/doc/python3-postgresql/html/reference.html is in python3-postgresql 1.1.0-1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Reference — py-postgresql 1.1.0 documentation</title>
<link rel="stylesheet" href="_static/default.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '1.1.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="py-postgresql 1.1.0 documentation" href="index.html" />
<link rel="next" title="Changes in v1.1" href="changes-v1.1.html" />
<link rel="prev" title="Commands" href="bin.html" />
<link rel="stylesheet" href="_static/unsuck.css" type="text/css" />
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="changes-v1.1.html" title="Changes in v1.1"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="bin.html" title="Commands"
accesskey="P">previous</a> |</li>
<li><a href="index.html">py-postgresql 1.1.0 documentation</a> »</li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="reference">
<h1>Reference<a class="headerlink" href="#reference" title="Permalink to this headline">¶</a></h1>
<div class="section" id="module-postgresql">
<span id="postgresql"></span><h2><a class="reference internal" href="#module-postgresql" title="postgresql"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql</span></tt></a><a class="headerlink" href="#module-postgresql" title="Permalink to this headline">¶</a></h2>
<p>py-postgresql is a Python package for using PostgreSQL. This includes low-level
protocol tools, a driver(PG-API and DB-API), and cluster management tools.</p>
<p>If it’s not documented in the narratives, <cite>postgresql.documentation.index</cite>, then
the stability of the APIs should <em>not</em> be trusted.</p>
<p>See <<a class="reference external" href="http://postgresql.org">http://postgresql.org</a>> for more information about PostgreSQL.</p>
<dl class="data">
<dt id="postgresql.version">
<tt class="descclassname">postgresql.</tt><tt class="descname">version</tt><em class="property"> = '1.1.0'</em><a class="headerlink" href="#postgresql.version" title="Permalink to this definition">¶</a></dt>
<dd><p>The version string of py-postgresql.</p>
</dd></dl>
<dl class="data">
<dt id="postgresql.version_info">
<tt class="descclassname">postgresql.</tt><tt class="descname">version_info</tt><em class="property"> = (1, 1, 0)</em><a class="headerlink" href="#postgresql.version_info" title="Permalink to this definition">¶</a></dt>
<dd><p>The version triple of py-postgresql: (major, minor, patch).</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.open">
<tt class="descclassname">postgresql.</tt><tt class="descname">open</tt><big>(</big><em>iri=None</em>, <em>prompt_title=None</em>, <em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql.html#open"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.open" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a <cite>postgresql.api.Connection</cite> to the server referenced by the given
<cite>iri</cite>:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="kn">import</span> <span class="nn">postgresql</span>
<span class="go"># General Format:</span>
<span class="gp">>>> </span><span class="n">db</span> <span class="o">=</span> <span class="n">postgresql</span><span class="o">.</span><span class="n">open</span><span class="p">(</span><span class="s">'pq://user:password@host:port/database'</span><span class="p">)</span>
<span class="go"># Connect to 'postgres' at localhost.</span>
<span class="gp">>>> </span><span class="n">db</span> <span class="o">=</span> <span class="n">postgresql</span><span class="o">.</span><span class="n">open</span><span class="p">(</span><span class="s">'localhost/postgres'</span><span class="p">)</span>
</pre></div>
</div>
<p>Connection keywords can also be used with <cite>open</cite>. See the narratives for
more information.</p>
<p>The <cite>prompt_title</cite> keyword is ignored. <cite>open</cite> will never prompt for
the password unless it is explicitly instructed to do so.</p>
<p>(Note: “pq” is the name of the protocol used to communicate with PostgreSQL)</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.api">
<span id="postgresql-api"></span><h2><a class="reference internal" href="#module-postgresql.api" title="postgresql.api"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.api</span></tt></a><a class="headerlink" href="#module-postgresql.api" title="Permalink to this headline">¶</a></h2>
<p>Application Programmer Interfaces for PostgreSQL.</p>
<p><tt class="docutils literal"><span class="pre">postgresql.api</span></tt> is a collection of Python APIs for the PostgreSQL DBMS. It
is designed to take full advantage of PostgreSQL’s features to provide the
Python programmer with substantial convenience.</p>
<p>This module is used to define “PG-API”. It creates a set of ABCs
that makes up the basic interfaces used to work with a PostgreSQL server.</p>
<dl class="class">
<dt id="postgresql.api.Message">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Message</tt><a class="reference internal" href="_modules/postgresql/api.html#Message"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>A message emitted by PostgreSQL.
A message being a NOTICE, WARNING, INFO, etc.</p>
<dl class="attribute">
<dt id="postgresql.api.Message.code">
<tt class="descname">code</tt><a class="reference internal" href="_modules/postgresql/api.html#Message.code"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message.code" title="Permalink to this definition">¶</a></dt>
<dd><p>The SQL state code of the message.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Message.details">
<tt class="descname">details</tt><a class="reference internal" href="_modules/postgresql/api.html#Message.details"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message.details" title="Permalink to this definition">¶</a></dt>
<dd><p>The additional details given with the message. Common keys <em>should</em> be the
following:</p>
<blockquote>
<div><ul class="simple">
<li>‘severity’</li>
<li>‘context’</li>
<li>‘detail’</li>
<li>‘hint’</li>
<li>‘file’</li>
<li>‘line’</li>
<li>‘function’</li>
<li>‘position’</li>
<li>‘internal_position’</li>
<li>‘internal_query’</li>
</ul>
</div></blockquote>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Message.isconsistent">
<tt class="descname">isconsistent</tt><big>(</big><em>other</em><big>)</big> → bool<a class="reference internal" href="_modules/postgresql/api.html#Message.isconsistent"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message.isconsistent" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether the fields of the <cite>other</cite> Message object is consistent with the
fields of <cite>self</cite>.</p>
<p>This <em>must</em> return the result of the comparison of code, source, message,
and details.</p>
<p>This method is provided as the alternative to overriding equality;
often, pointer equality is the desirable means for comparison, but
equality of the fields is also necessary.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Message.message">
<tt class="descname">message</tt><a class="reference internal" href="_modules/postgresql/api.html#Message.message"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message.message" title="Permalink to this definition">¶</a></dt>
<dd><p>The primary message string.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Message.source">
<tt class="descname">source</tt><a class="reference internal" href="_modules/postgresql/api.html#Message.source"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Message.source" title="Permalink to this definition">¶</a></dt>
<dd><p>Where the message originated from. Normally, ‘SERVER’, but sometimes
‘CLIENT’.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Statement">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Statement</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Callable</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Iterable</span></tt></p>
<p>Instances of <cite>Statement</cite> are returned by the <cite>prepare</cite> method of
<cite>Database</cite> instances.</p>
<p>A Statement is an Iterable as well as Callable.</p>
<p>The Iterable interface is supported for queries that take no arguments at
all. It allows the syntax:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="k">for</span> <span class="n">x</span> <span class="ow">in</span> <span class="n">db</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="s">'select * FROM table'</span><span class="p">):</span>
<span class="gp">... </span> <span class="k">pass</span>
</pre></div>
</div>
<dl class="method">
<dt id="postgresql.api.Statement.clone">
<tt class="descname">clone</tt><big>(</big><big>)</big> → 'Statement'<a class="reference internal" href="_modules/postgresql/api.html#Statement.clone"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.clone" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a new statement object using the same factors as <cite>self</cite>.</p>
<p>When used for refreshing plans, the new clone should replace references to
the original.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Statement.close">
<tt class="descname">close</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Statement.close"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.close" title="Permalink to this definition">¶</a></dt>
<dd><p>Close the prepared statement releasing resources associated with it.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.column_names">
<tt class="descname">column_names</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.column_names"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.column_names" title="Permalink to this definition">¶</a></dt>
<dd><p>The attribute names of the columns produced by the statement.</p>
<p>A sequence of <cite>str</cite> objects stating the column name:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="s">'column1'</span><span class="p">,</span> <span class="s">'column2'</span><span class="p">,</span> <span class="s">'emp_name'</span><span class="p">]</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.column_types">
<tt class="descname">column_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.column_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.column_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The Python types of the columns produced by the statement.</p>
<p>A sequence of type objects:</p>
<div class="highlight-python"><div class="highlight"><pre>[<class 'int'>, <class 'str'>]
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.parameter_types">
<tt class="descname">parameter_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.parameter_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.parameter_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The Python types expected of parameters given to the statement.</p>
<p>A sequence of type objects:</p>
<div class="highlight-python"><div class="highlight"><pre>[<class 'int'>, <class 'str'>]
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.pg_column_types">
<tt class="descname">pg_column_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.pg_column_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.pg_column_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The type Oids of the columns produced by the statement.</p>
<p>A sequence of <cite>int</cite> objects stating the SQL type name:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="mi">27</span><span class="p">,</span> <span class="mi">28</span><span class="p">]</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.pg_parameter_types">
<tt class="descname">pg_parameter_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.pg_parameter_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.pg_parameter_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The type Oids of the parameters required by the statement.</p>
<p>A sequence of <cite>int</cite> objects stating the PostgreSQL type Oid:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="mi">27</span><span class="p">,</span> <span class="mi">28</span><span class="p">]</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.sql_column_types">
<tt class="descname">sql_column_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.sql_column_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.sql_column_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The type of the columns produced by the statement.</p>
<p>A sequence of <cite>str</cite> objects stating the SQL type name:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="s">'INTEGER'</span><span class="p">,</span> <span class="s">'VARCHAR'</span><span class="p">,</span> <span class="s">'INTERVAL'</span><span class="p">]</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.sql_parameter_types">
<tt class="descname">sql_parameter_types</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.sql_parameter_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.sql_parameter_types" title="Permalink to this definition">¶</a></dt>
<dd><p>The type of the parameters required by the statement.</p>
<p>A sequence of <cite>str</cite> objects stating the SQL type name:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">[</span><span class="s">'INTEGER'</span><span class="p">,</span> <span class="s">'VARCHAR'</span><span class="p">,</span> <span class="s">'INTERVAL'</span><span class="p">]</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.statement_id">
<tt class="descname">statement_id</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.statement_id"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.statement_id" title="Permalink to this definition">¶</a></dt>
<dd><p>The statment’s identifier.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Statement.string">
<tt class="descname">string</tt><a class="reference internal" href="_modules/postgresql/api.html#Statement.string"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Statement.string" title="Permalink to this definition">¶</a></dt>
<dd><p>The SQL string of the prepared statement.</p>
<p><cite>None</cite> if not available. This can happen in cases where a statement is
prepared on the server and a reference to the statement is sent to the
client which subsequently uses the statement via the <cite>Database</cite>‘s
<cite>statement</cite> constructor.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Cursor">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Cursor</tt><a class="reference internal" href="_modules/postgresql/api.html#Cursor"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cursor" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.api.Result</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Iterator</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Iterable</span></tt></p>
<p>A <cite>Cursor</cite> object is an interface to a sequence of tuples(rows). A result
set. Cursors publish a file-like interface for reading tuples from a cursor
declared on the database.</p>
<p><cite>Cursor</cite> objects are created by invoking the <cite>Statement.declare</cite>
method or by opening a cursor using an identifier via the
<cite>Database.cursor_from_id</cite> method.</p>
<dl class="method">
<dt id="postgresql.api.Cursor.clone">
<tt class="descname">clone</tt><big>(</big><big>)</big> → 'Cursor'<a class="reference internal" href="_modules/postgresql/api.html#Cursor.clone"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cursor.clone" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a new cursor using the same factors as <cite>self</cite>.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Cursor.direction">
<tt class="descname">direction</tt><a class="reference internal" href="_modules/postgresql/api.html#Cursor.direction"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cursor.direction" title="Permalink to this definition">¶</a></dt>
<dd><p>The default <cite>direction</cite> argument for read().</p>
<p>When <cite>True</cite> reads are FORWARD.
When <cite>False</cite> reads are BACKWARD.</p>
<p>Cursor operation option.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cursor.read">
<tt class="descname">read</tt><big>(</big><em>quantity: 'Number of rows to read'=None</em>, <em>direction: 'Direction to fetch in</em>, <em>defaults to `self.direction`'=None</em><big>)</big> → ['Row']<a class="reference internal" href="_modules/postgresql/api.html#Cursor.read"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cursor.read" title="Permalink to this definition">¶</a></dt>
<dd><p>Read, fetch, the specified number of rows and return them in a list.
If quantity is <cite>None</cite>, all records will be fetched.</p>
<p><cite>direction</cite> can be used to override the default configured direction.</p>
<p>This alters the cursor’s position.</p>
<p>Read does not directly correlate to FETCH. If zero is given as the
quantity, an empty sequence <em>must</em> be returned.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cursor.seek">
<tt class="descname">seek</tt><big>(</big><em>offset</em>, <em>whence='ABSOLUTE'</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cursor.seek"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cursor.seek" title="Permalink to this definition">¶</a></dt>
<dd><p>Set the cursor’s position to the given offset with respect to the
whence parameter and the configured direction.</p>
<p>Whence values:</p>
<blockquote>
<div><dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">0</span></tt> or <tt class="docutils literal"><span class="pre">"ABSOLUTE"</span></tt></dt>
<dd>Absolute.</dd>
<dt><tt class="docutils literal"><span class="pre">1</span></tt> or <tt class="docutils literal"><span class="pre">"RELATIVE"</span></tt></dt>
<dd>Relative.</dd>
<dt><tt class="docutils literal"><span class="pre">2</span></tt> or <tt class="docutils literal"><span class="pre">"FROM_END"</span></tt></dt>
<dd>Absolute from end.</dd>
<dt><tt class="docutils literal"><span class="pre">3</span></tt> or <tt class="docutils literal"><span class="pre">"FORWARD"</span></tt></dt>
<dd>Relative forward.</dd>
<dt><tt class="docutils literal"><span class="pre">4</span></tt> or <tt class="docutils literal"><span class="pre">"BACKWARD"</span></tt></dt>
<dd>Relative backward.</dd>
</dl>
</div></blockquote>
<p>Direction effects whence. If direction is BACKWARD, ABSOLUTE positioning
will effectively be FROM_END, RELATIVE’s position will be negated, and
FROM_END will effectively be ABSOLUTE.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Connector">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Connector</tt><big>(</big><em>user: 'required keyword specifying the user name(str)'=None, password: str=None, database: str=None, settings: (<class 'dict'>, [(<class 'str'>, <class 'str'>)])=None, category: postgresql.api.Category=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Connector"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connector" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>A connector is an object providing the necessary information to establish a
connection. This includes credentials, database settings, and many times
addressing information.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Category">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Category</tt><a class="reference internal" href="_modules/postgresql/api.html#Category"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Category" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>A category is an object that initializes the subject connection for a
specific purpose.</p>
<p>Arguably, a runtime class for use with connections.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Database">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Database</tt><a class="reference internal" href="_modules/postgresql/api.html#Database"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>The interface to an individual database. <cite>Connection</cite> objects inherit from
this</p>
<dl class="attribute">
<dt id="postgresql.api.Database.backend_id">
<tt class="descname">backend_id</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.backend_id"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.backend_id" title="Permalink to this definition">¶</a></dt>
<dd><p>The backend’s process identifier.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Database.client_address">
<tt class="descname">client_address</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.client_address"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.client_address" title="Permalink to this definition">¶</a></dt>
<dd><p>The client address that the server sees. This is obtainable by querying
the <tt class="docutils literal"><span class="pre">pg_catalog.pg_stat_activity</span></tt> relation.</p>
<p><cite>None</cite> if unavailable.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Database.client_port">
<tt class="descname">client_port</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.client_port"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.client_port" title="Permalink to this definition">¶</a></dt>
<dd><p>The client port that the server sees. This is obtainable by querying
the <tt class="docutils literal"><span class="pre">pg_catalog.pg_stat_activity</span></tt> relation.</p>
<p><cite>None</cite> if unavailable.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.cursor_from_id">
<tt class="descname">cursor_from_id</tt><big>(</big><em>cursor_id: "The cursor's identification string."</em><big>)</big> → postgresql.api.Cursor<a class="reference internal" href="_modules/postgresql/api.html#Database.cursor_from_id"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.cursor_from_id" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a <cite>Cursor</cite> object from the given <cite>cursor_id</cite> that was already
declared on the server.</p>
<p><cite>Cursor</cite> objects created this way must <em>not</em> be closed when the object
is garbage collected. Rather, the user must explicitly close it for
the server resources to be released. This is in contrast to <cite>Cursor</cite>
objects that are created by invoking a <cite>Statement</cite> or a SRF
<cite>StoredProcedure</cite>.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.do">
<tt class="descname">do</tt><big>(</big><em>language</em>, <em>source</em><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Database.do"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.do" title="Permalink to this definition">¶</a></dt>
<dd><p>Execute a DO statement using the given language and source.
Always returns <cite>None</cite>.</p>
<p>Likely to be a function of Connection.execute.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.execute">
<tt class="descname">execute</tt><big>(</big><em>sql</em><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Database.execute"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.execute" title="Permalink to this definition">¶</a></dt>
<dd><p>Execute an arbitrary block of SQL. Always returns <cite>None</cite> and raise
an exception on error.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.iternotifies">
<tt class="descname">iternotifies</tt><big>(</big><em>timeout=None</em><big>)</big> → collections.abc.Iterator<a class="reference internal" href="_modules/postgresql/api.html#Database.iternotifies"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.iternotifies" title="Permalink to this definition">¶</a></dt>
<dd><p>Return an iterator to the notifications received by the connection. The
iterator <em>must</em> produce triples in the form <tt class="docutils literal"><span class="pre">(channel,</span> <span class="pre">payload,</span> <span class="pre">pid)</span></tt>.</p>
<p>If timeout is not <cite>None</cite>, <cite>None</cite> <em>must</em> be emitted at the specified
timeout interval. If the timeout is zero, all the pending notifications
<em>must</em> be yielded by the iterator and then <cite>StopIteration</cite> <em>must</em> be
raised.</p>
<p>If the connection is closed for any reason, the iterator <em>must</em> silently
stop by raising <cite>StopIteration</cite>. Further error control is then the
responsibility of the user.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.listen">
<tt class="descname">listen</tt><big>(</big><em>*channels</em><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Database.listen"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.listen" title="Permalink to this definition">¶</a></dt>
<dd><p>Start listening to the given channels.</p>
<p>Equivalent to issuing “LISTEN <x>” for x in channels.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.listening_channels">
<tt class="descname">listening_channels</tt><big>(</big><big>)</big> → ['channel name', Ellipsis]<a class="reference internal" href="_modules/postgresql/api.html#Database.listening_channels"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.listening_channels" title="Permalink to this definition">¶</a></dt>
<dd><p>Return an <em>iterator</em> to all the channels currently being listened to.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.notify">
<tt class="descname">notify</tt><big>(</big><em>*channels</em>, <em>**channel_and_payload</em><big>)</big> → int<a class="reference internal" href="_modules/postgresql/api.html#Database.notify"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.notify" title="Permalink to this definition">¶</a></dt>
<dd><p>NOTIFY the channels with the given payload.</p>
<p>Equivalent to issuing “NOTIFY <channel>” or “NOTIFY <channel>, <payload>”
for each item in <cite>channels</cite> and <cite>channel_and_payload</cite>. All NOTIFYs issued
<em>must</em> occur in the same transaction.</p>
<p>The items in <cite>channels</cite> can either be a string or a tuple. If a string,
no payload is given, but if an item is a <cite>builtins.tuple</cite>, the second item
will be given as the payload. <cite>channels</cite> offers a means to issue NOTIFYs
in guaranteed order.</p>
<p>The items in <cite>channel_and_payload</cite> are all payloaded NOTIFYs where the
keys are the channels and the values are the payloads. Order is undefined.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.prepare">
<tt class="descname">prepare</tt><big>(</big><em>sql: str</em><big>)</big> → postgresql.api.Statement<a class="reference internal" href="_modules/postgresql/api.html#Database.prepare"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.prepare" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a new <cite>Statement</cite> instance bound to the connection
using the given SQL.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="n">s</span> <span class="o">=</span> <span class="n">db</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="s">"SELECT 1"</span><span class="p">)</span>
<span class="gp">>>> </span><span class="n">c</span> <span class="o">=</span> <span class="n">s</span><span class="p">()</span>
<span class="gp">>>> </span><span class="n">c</span><span class="o">.</span><span class="n">next</span><span class="p">()</span>
<span class="go">(1,)</span>
</pre></div>
</div>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.proc">
<tt class="descname">proc</tt><big>(</big><em>procedure_id: 'The procedure identifier; a valid ``regprocedure`` or Oid.'</em><big>)</big> → postgresql.api.StoredProcedure<a class="reference internal" href="_modules/postgresql/api.html#Database.proc"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.proc" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a <cite>StoredProcedure</cite> instance using the given identifier.</p>
<p>The <cite>proc_id</cite> given can be either an <tt class="docutils literal"><span class="pre">Oid</span></tt>, or a <tt class="docutils literal"><span class="pre">regprocedure</span></tt>
that identifies the stored procedure to create the interface for.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="n">p</span> <span class="o">=</span> <span class="n">db</span><span class="o">.</span><span class="n">proc</span><span class="p">(</span><span class="s">'version()'</span><span class="p">)</span>
<span class="gp">>>> </span><span class="n">p</span><span class="p">()</span>
<span class="go">'PostgreSQL 8.3.0'</span>
<span class="gp">>>> </span><span class="n">qstr</span> <span class="o">=</span> <span class="s">"select oid from pg_proc where proname = 'generate_series'"</span>
<span class="gp">>>> </span><span class="n">db</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="n">qstr</span><span class="p">)</span><span class="o">.</span><span class="n">first</span><span class="p">()</span>
<span class="go">1069</span>
<span class="gp">>>> </span><span class="n">generate_series</span> <span class="o">=</span> <span class="n">db</span><span class="o">.</span><span class="n">proc</span><span class="p">(</span><span class="mi">1069</span><span class="p">)</span>
<span class="gp">>>> </span><span class="nb">list</span><span class="p">(</span><span class="n">generate_series</span><span class="p">(</span><span class="mi">1</span><span class="p">,</span><span class="mi">5</span><span class="p">))</span>
<span class="go">[1, 2, 3, 4, 5]</span>
</pre></div>
</div>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.reset">
<tt class="descname">reset</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Database.reset"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.reset" title="Permalink to this definition">¶</a></dt>
<dd><p>Reset the connection into it’s original state.</p>
<p>Issues a <tt class="docutils literal"><span class="pre">RESET</span> <span class="pre">ALL</span></tt> to the database. If the database supports
removing temporary tables created in the session, then remove them.
Reapply initial configuration settings such as path.</p>
<p>The purpose behind this method is to provide a soft-reconnect method
that re-initializes the connection into its original state. One
obvious use of this would be in a connection pool where the connection
is being recycled.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Database.settings">
<tt class="descname">settings</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.settings"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.settings" title="Permalink to this definition">¶</a></dt>
<dd><p>A <cite>Settings</cite> instance bound to the <cite>Database</cite>.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.statement_from_id">
<tt class="descname">statement_from_id</tt><big>(</big><em>statement_id: "The statement's identification string."</em><big>)</big> → postgresql.api.Statement<a class="reference internal" href="_modules/postgresql/api.html#Database.statement_from_id"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.statement_from_id" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a <cite>Statement</cite> object that was already prepared on the
server. The distinction between this and a regular query is that it
must be explicitly closed if it is no longer desired, and it is
instantiated using the statement identifier as opposed to the SQL
statement itself.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Database.unlisten">
<tt class="descname">unlisten</tt><big>(</big><em>*channels</em><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Database.unlisten"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.unlisten" title="Permalink to this definition">¶</a></dt>
<dd><p>Stop listening to the given channels.</p>
<p>Equivalent to issuing “UNLISTEN <x>” for x in channels.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Database.version_info">
<tt class="descname">version_info</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.version_info"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.version_info" title="Permalink to this definition">¶</a></dt>
<dd><p>A version tuple of the database software similar Python’s <cite>sys.version_info</cite>.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="n">db</span><span class="o">.</span><span class="n">version_info</span>
<span class="go">(8, 1, 3, '', 0)</span>
</pre></div>
</div>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Database.xact">
<tt class="descname">xact</tt><a class="reference internal" href="_modules/postgresql/api.html#Database.xact"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Database.xact" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a <cite>Transaction</cite> object using the given keyword arguments as its
configuration.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Connection">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Connection</tt><a class="reference internal" href="_modules/postgresql/api.html#Connection"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.api.Database" title="postgresql.api.Database"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.api.Database</span></tt></a></p>
<p>The interface to a connection to a PostgreSQL database. This is a
<cite>Database</cite> interface with the additional connection management tools that
are particular to using a remote database.</p>
<dl class="method">
<dt id="postgresql.api.Connection.clone">
<tt class="descname">clone</tt><big>(</big><big>)</big> → 'Connection'<a class="reference internal" href="_modules/postgresql/api.html#Connection.clone"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.clone" title="Permalink to this definition">¶</a></dt>
<dd><p>Create another connection using the same factors as <cite>self</cite>. The returned
object should be open and ready for use.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Connection.close">
<tt class="descname">close</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Connection.close"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.close" title="Permalink to this definition">¶</a></dt>
<dd><p>Close the connection.</p>
<p>Does nothing if the connection is already closed.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Connection.closed">
<tt class="descname">closed</tt><a class="reference internal" href="_modules/postgresql/api.html#Connection.closed"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.closed" title="Permalink to this definition">¶</a></dt>
<dd><p><cite>True</cite> if the <cite>Connection</cite> is closed, <cite>False</cite> if the <cite>Connection</cite> is
open.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="n">db</span><span class="o">.</span><span class="n">closed</span>
<span class="go">True</span>
</pre></div>
</div>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Connection.connect">
<tt class="descname">connect</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Connection.connect"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.connect" title="Permalink to this definition">¶</a></dt>
<dd><p>Establish the connection to the server and initialize the category.</p>
<p>Does nothing if the connection is already established.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Connection.connector">
<tt class="descname">connector</tt><a class="reference internal" href="_modules/postgresql/api.html#Connection.connector"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.connector" title="Permalink to this definition">¶</a></dt>
<dd><p>The <a class="reference internal" href="#postgresql.api.Connector" title="postgresql.api.Connector"><tt class="xref py py-class docutils literal"><span class="pre">Connector</span></tt></a> instance facilitating the <cite>Connection</cite> object’s
communication and initialization.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Connection.query">
<tt class="descname">query</tt><a class="reference internal" href="_modules/postgresql/api.html#Connection.query"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Connection.query" title="Permalink to this definition">¶</a></dt>
<dd><p>The <tt class="xref py py-class docutils literal"><span class="pre">Execution</span></tt> instance providing a one-shot query interface:</p>
<div class="highlight-python"><div class="highlight"><pre>connection.query.<method>(sql, *parameters) == connection.prepare(sql).<method>(*parameters)
</pre></div>
</div>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Transaction">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Transaction</tt><a class="reference internal" href="_modules/postgresql/api.html#Transaction"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>A <cite>Tranaction</cite> is an element that represents a transaction in the session.
Once created, it’s ready to be started, and subsequently committed or
rolled back.</p>
<p>Read-only transaction:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="k">with</span> <span class="n">db</span><span class="o">.</span><span class="n">xact</span><span class="p">(</span><span class="n">mode</span> <span class="o">=</span> <span class="s">'read only'</span><span class="p">):</span>
<span class="gp">... </span> <span class="o">...</span>
</pre></div>
</div>
<p>Read committed isolation:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="k">with</span> <span class="n">db</span><span class="o">.</span><span class="n">xact</span><span class="p">(</span><span class="n">isolation</span> <span class="o">=</span> <span class="s">'READ COMMITTED'</span><span class="p">):</span>
<span class="gp">... </span> <span class="o">...</span>
</pre></div>
</div>
<p>Savepoints are created if inside a transaction block:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="k">with</span> <span class="n">db</span><span class="o">.</span><span class="n">xact</span><span class="p">():</span>
<span class="gp">... </span> <span class="k">with</span> <span class="n">db</span><span class="o">.</span><span class="n">xact</span><span class="p">():</span>
<span class="gp">... </span> <span class="o">...</span>
</pre></div>
</div>
<dl class="method">
<dt id="postgresql.api.Transaction.abort">
<tt class="descname">abort</tt><big>(</big><big>)</big> → None<a class="headerlink" href="#postgresql.api.Transaction.abort" title="Permalink to this definition">¶</a></dt>
<dd><p>Abort the transaction.</p>
<p>If the transaction is a savepoint, ROLLBACK TO the savepoint identifier.</p>
<p>If the transaction is a transaction block, issue an ABORT.</p>
<p>If the transaction has already been aborted, do nothing.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Transaction.begin">
<tt class="descname">begin</tt><big>(</big><big>)</big> → None<a class="headerlink" href="#postgresql.api.Transaction.begin" title="Permalink to this definition">¶</a></dt>
<dd><p>Start the transaction.</p>
<p>If the database is in a transaction block, the transaction should be
configured as a savepoint. If any transaction block configuration was
applied to the transaction, raise a <cite>postgresql.exceptions.OperationError</cite>.</p>
<p>If the database is not in a transaction block, start one using the
configuration where:</p>
<p><cite>self.isolation</cite> specifies the <tt class="docutils literal"><span class="pre">ISOLATION</span> <span class="pre">LEVEL</span></tt>. Normally, <tt class="docutils literal"><span class="pre">READ</span>
<span class="pre">COMMITTED</span></tt>, <tt class="docutils literal"><span class="pre">SERIALIZABLE</span></tt>, or <tt class="docutils literal"><span class="pre">READ</span> <span class="pre">UNCOMMITTED</span></tt>.</p>
<p><cite>self.mode</cite> specifies the mode of the transaction. Normally, <tt class="docutils literal"><span class="pre">READ</span>
<span class="pre">ONLY</span></tt> or <tt class="docutils literal"><span class="pre">READ</span> <span class="pre">WRITE</span></tt>.</p>
<p>If the transaction is already open, do nothing.</p>
<p>If the transaction has been committed or aborted, raise an
<cite>postgresql.exceptions.OperationError</cite>.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Transaction.commit">
<tt class="descname">commit</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Transaction.commit"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction.commit" title="Permalink to this definition">¶</a></dt>
<dd><p>Commit the transaction.</p>
<p>If the transaction is a block, issue a COMMIT statement.</p>
<p>If the transaction was started inside a transaction block, it should be
identified as a savepoint, and the savepoint should be released.</p>
<p>If the transaction has already been committed, do nothing.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Transaction.isolation">
<tt class="descname">isolation</tt><a class="reference internal" href="_modules/postgresql/api.html#Transaction.isolation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction.isolation" title="Permalink to this definition">¶</a></dt>
<dd><p>The isolation level of the transaction block:</p>
<blockquote>
<div>START TRANSACTION <isolation> [MODE];</div></blockquote>
<p>The <cite>isolation</cite> property is a string and will be directly interpolated into
the START TRANSACTION statement.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Transaction.mode">
<tt class="descname">mode</tt><a class="reference internal" href="_modules/postgresql/api.html#Transaction.mode"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction.mode" title="Permalink to this definition">¶</a></dt>
<dd><p>The mode of the transaction block:</p>
<blockquote>
<div>START TRANSACTION [ISOLATION] <mode>;</div></blockquote>
<p>The <cite>mode</cite> property is a string and will be directly interpolated into the
START TRANSACTION statement.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Transaction.rollback">
<tt class="descname">rollback</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Transaction.rollback"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction.rollback" title="Permalink to this definition">¶</a></dt>
<dd><p>Abort the transaction.</p>
<p>If the transaction is a savepoint, ROLLBACK TO the savepoint identifier.</p>
<p>If the transaction is a transaction block, issue an ABORT.</p>
<p>If the transaction has already been aborted, do nothing.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Transaction.start">
<tt class="descname">start</tt><big>(</big><big>)</big> → None<a class="reference internal" href="_modules/postgresql/api.html#Transaction.start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Transaction.start" title="Permalink to this definition">¶</a></dt>
<dd><p>Start the transaction.</p>
<p>If the database is in a transaction block, the transaction should be
configured as a savepoint. If any transaction block configuration was
applied to the transaction, raise a <cite>postgresql.exceptions.OperationError</cite>.</p>
<p>If the database is not in a transaction block, start one using the
configuration where:</p>
<p><cite>self.isolation</cite> specifies the <tt class="docutils literal"><span class="pre">ISOLATION</span> <span class="pre">LEVEL</span></tt>. Normally, <tt class="docutils literal"><span class="pre">READ</span>
<span class="pre">COMMITTED</span></tt>, <tt class="docutils literal"><span class="pre">SERIALIZABLE</span></tt>, or <tt class="docutils literal"><span class="pre">READ</span> <span class="pre">UNCOMMITTED</span></tt>.</p>
<p><cite>self.mode</cite> specifies the mode of the transaction. Normally, <tt class="docutils literal"><span class="pre">READ</span>
<span class="pre">ONLY</span></tt> or <tt class="docutils literal"><span class="pre">READ</span> <span class="pre">WRITE</span></tt>.</p>
<p>If the transaction is already open, do nothing.</p>
<p>If the transaction has been committed or aborted, raise an
<cite>postgresql.exceptions.OperationError</cite>.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Settings">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Settings</tt><a class="reference internal" href="_modules/postgresql/api.html#Settings"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.MutableMapping</span></tt></p>
<p>A mapping interface to the session’s settings. This provides a direct
interface to <tt class="docutils literal"><span class="pre">SHOW</span></tt> or <tt class="docutils literal"><span class="pre">SET</span></tt> commands. Identifiers and values need
not be quoted specially as the implementation must do that work for the
user.</p>
<dl class="method">
<dt id="postgresql.api.Settings.get">
<tt class="descname">get</tt><big>(</big><em>key</em>, <em>default=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.get"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.get" title="Permalink to this definition">¶</a></dt>
<dd><p>Get the setting with the corresponding key. If the setting does not
exist, return the <cite>default</cite>.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Settings.getset">
<tt class="descname">getset</tt><big>(</big><em>keys</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.getset"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.getset" title="Permalink to this definition">¶</a></dt>
<dd><p>Return a dictionary containing the key-value pairs of the requested
settings. If <em>any</em> of the keys do not exist, a <cite>KeyError</cite> must be raised
with the set of keys that did not exist.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Settings.items">
<tt class="descname">items</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.items"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.items" title="Permalink to this definition">¶</a></dt>
<dd><p>Return an iterator to all of the setting value pairs.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Settings.keys">
<tt class="descname">keys</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.keys"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.keys" title="Permalink to this definition">¶</a></dt>
<dd><p>Return an iterator to all of the settings’ keys.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Settings.update">
<tt class="descname">update</tt><big>(</big><em>mapping</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.update"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.update" title="Permalink to this definition">¶</a></dt>
<dd><p>For each key-value pair, incur the effect of the <cite>__setitem__</cite> method.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Settings.values">
<tt class="descname">values</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Settings.values"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Settings.values" title="Permalink to this definition">¶</a></dt>
<dd><p>Return an iterator to all of the settings’ values.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.StoredProcedure">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">StoredProcedure</tt><a class="reference internal" href="_modules/postgresql/api.html#StoredProcedure"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.StoredProcedure" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Callable</span></tt></p>
<p>A function stored on the database.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Driver">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Driver</tt><a class="reference internal" href="_modules/postgresql/api.html#Driver"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Driver" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>The <cite>Driver</cite> element provides the <cite>Connector</cite> and other information
pertaining to the implementation of the driver. Information about what the
driver supports is available in instances.</p>
<dl class="method">
<dt id="postgresql.api.Driver.connect">
<tt class="descname">connect</tt><big>(</big><em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Driver.connect"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Driver.connect" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a connection using the given parameters for the Connector.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Installation">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Installation</tt><a class="reference internal" href="_modules/postgresql/api.html#Installation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Installation" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>Interface to a PostgreSQL installation. Instances would provide various
information about an installation of PostgreSQL accessible by the Python</p>
<dl class="attribute">
<dt id="postgresql.api.Installation.ssl">
<tt class="descname">ssl</tt><a class="reference internal" href="_modules/postgresql/api.html#Installation.ssl"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Installation.ssl" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether the installation supports SSL.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Installation.type">
<tt class="descname">type</tt><a class="reference internal" href="_modules/postgresql/api.html#Installation.type"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Installation.type" title="Permalink to this definition">¶</a></dt>
<dd><p>The “type” of PostgreSQL. Normally, the first component of the string
returned by pg_config.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Installation.version">
<tt class="descname">version</tt><a class="reference internal" href="_modules/postgresql/api.html#Installation.version"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Installation.version" title="Permalink to this definition">¶</a></dt>
<dd><p>A version string consistent with what <cite>SELECT version()</cite> would output.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Installation.version_info">
<tt class="descname">version_info</tt><a class="reference internal" href="_modules/postgresql/api.html#Installation.version_info"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Installation.version_info" title="Permalink to this definition">¶</a></dt>
<dd><p>A tuple specifying the version in a form similar to Python’s
sys.version_info. (8, 3, 3, ‘final’, 0)</p>
<p>See <cite>postgresql.versionstring</cite>.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.api.Cluster">
<em class="property">class </em><tt class="descclassname">postgresql.api.</tt><tt class="descname">Cluster</tt><a class="reference internal" href="_modules/postgresql/api.html#Cluster"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>Interface to a PostgreSQL cluster–a data directory. An implementation of
this provides a means to control a server.</p>
<dl class="attribute">
<dt id="postgresql.api.Cluster.data_directory">
<tt class="descname">data_directory</tt><a class="reference internal" href="_modules/postgresql/api.html#Cluster.data_directory"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.data_directory" title="Permalink to this definition">¶</a></dt>
<dd><p>The path to the data directory of the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.drop">
<tt class="descname">drop</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.drop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.drop" title="Permalink to this definition">¶</a></dt>
<dd><p>Kill the server and completely remove the data directory.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.init">
<tt class="descname">init</tt><big>(</big><em>initdb: 'path to the initdb to use'=None</em>, <em>user: "name of the cluster's superuser"=None</em>, <em>password: "superuser's password"=None</em>, <em>encoding: 'the encoding to use for the cluster'=None</em>, <em>locale: 'the locale to use for the cluster'=None</em>, <em>collate: 'the collation to use for the cluster'=None</em>, <em>ctype: 'the ctype to use for the cluster'=None</em>, <em>monetary: 'the monetary to use for the cluster'=None</em>, <em>numeric: 'the numeric to use for the cluster'=None</em>, <em>time: 'the time to use for the cluster'=None</em>, <em>text_search_config: 'default text search configuration'=None</em>, <em>xlogdir: 'location for the transaction log directory'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.init"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.init" title="Permalink to this definition">¶</a></dt>
<dd><p>Create the cluster at the <cite>data_directory</cite> associated with the Cluster
instance.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Cluster.installation">
<tt class="descname">installation</tt><a class="reference internal" href="_modules/postgresql/api.html#Cluster.installation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.installation" title="Permalink to this definition">¶</a></dt>
<dd><p>The installation used by the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.kill">
<tt class="descname">kill</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.kill"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.kill" title="Permalink to this definition">¶</a></dt>
<dd><p>Kill the server.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.restart">
<tt class="descname">restart</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.restart"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.restart" title="Permalink to this definition">¶</a></dt>
<dd><p>Restart the cluster.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.api.Cluster.settings">
<tt class="descname">settings</tt><a class="reference internal" href="_modules/postgresql/api.html#Cluster.settings"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.settings" title="Permalink to this definition">¶</a></dt>
<dd><p>A <cite>Settings</cite> interface to the <tt class="docutils literal"><span class="pre">postgresql.conf</span></tt> file associated with the
cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.start">
<tt class="descname">start</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.start" title="Permalink to this definition">¶</a></dt>
<dd><p>Start the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.stop">
<tt class="descname">stop</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.stop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.stop" title="Permalink to this definition">¶</a></dt>
<dd><p>Signal the server to shutdown.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.wait_until_started">
<tt class="descname">wait_until_started</tt><big>(</big><em>timeout: 'maximum time to wait'=10</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.wait_until_started"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.wait_until_started" title="Permalink to this definition">¶</a></dt>
<dd><p>After the start() method is ran, the database may not be ready for use.
This method provides a mechanism to block until the cluster is ready for
use.</p>
<p>If the <cite>timeout</cite> is reached, the method <em>must</em> throw a
<cite>postgresql.exceptions.ClusterTimeoutError</cite>.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.api.Cluster.wait_until_stopped">
<tt class="descname">wait_until_stopped</tt><big>(</big><em>timeout: 'maximum time to wait'=10</em><big>)</big><a class="reference internal" href="_modules/postgresql/api.html#Cluster.wait_until_stopped"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.api.Cluster.wait_until_stopped" title="Permalink to this definition">¶</a></dt>
<dd><p>After the stop() method is ran, the database may still be running.
This method provides a mechanism to block until the cluster is completely
shutdown.</p>
<p>If the <cite>timeout</cite> is reached, the method <em>must</em> throw a
<cite>postgresql.exceptions.ClusterTimeoutError</cite>.</p>
</dd></dl>
</dd></dl>
</div>
<div class="section" id="module-postgresql.sys">
<span id="postgresql-sys"></span><h2><a class="reference internal" href="#module-postgresql.sys" title="postgresql.sys"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.sys</span></tt></a><a class="headerlink" href="#module-postgresql.sys" title="Permalink to this headline">¶</a></h2>
<p>py-postgresql system functions and data.</p>
<div class="section" id="data">
<h3>Data<a class="headerlink" href="#data" title="Permalink to this headline">¶</a></h3>
<blockquote>
<div><dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">libpath</span></tt></dt>
<dd>The local file system paths that contain query libraries.</dd>
</dl>
</div></blockquote>
</div>
<div class="section" id="overridable-functions">
<h3>Overridable Functions<a class="headerlink" href="#overridable-functions" title="Permalink to this headline">¶</a></h3>
<blockquote>
<div><dl class="docutils">
<dt>excformat</dt>
<dd>Information that makes up an exception’s displayed “body”.
Effectively, the implementation of <cite>postgresql.exception.Error.__str__</cite></dd>
<dt>msghook</dt>
<dd>Display a message.</dd>
</dl>
</div></blockquote>
<dl class="function">
<dt id="postgresql.sys.default_errformat">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">default_errformat</tt><big>(</big><em>val</em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#default_errformat"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.default_errformat" title="Permalink to this definition">¶</a></dt>
<dd><p>Built-in error formatter. DON’T TOUCH!</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.sys.default_msghook">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">default_msghook</tt><big>(</big><em>msg</em>, <em>format_message=<function format_element at 0x2b06ae452730></em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#default_msghook"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.default_msghook" title="Permalink to this definition">¶</a></dt>
<dd><p>Built-in message hook. DON’T TOUCH!</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.sys.errformat">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">errformat</tt><big>(</big><em>*args</em>, <em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#errformat"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.errformat" title="Permalink to this definition">¶</a></dt>
<dd><p>Raised Database Error formatter pointing to default_excformat.</p>
<p>Override if you like. All postgresql.exceptions.Error’s are formatted using
this function.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.sys.msghook">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">msghook</tt><big>(</big><em>*args</em>, <em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#msghook"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.msghook" title="Permalink to this definition">¶</a></dt>
<dd><p>Message hook pointing to default_msghook.</p>
<p>Override if you like. All untrapped messages raised by
driver connections come here to be printed to stderr.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.sys.reset_errformat">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">reset_errformat</tt><big>(</big><em>with_func=<function errformat at 0x2b06ae314158></em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#reset_errformat"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.reset_errformat" title="Permalink to this definition">¶</a></dt>
<dd><p>restore the original excformat function</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.sys.reset_msghook">
<tt class="descclassname">postgresql.sys.</tt><tt class="descname">reset_msghook</tt><big>(</big><em>with_func=<function msghook at 0x2b06ae314400></em><big>)</big><a class="reference internal" href="_modules/postgresql/sys.html#reset_msghook"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.sys.reset_msghook" title="Permalink to this definition">¶</a></dt>
<dd><p>restore the original msghook function</p>
</dd></dl>
</div>
</div>
<div class="section" id="module-postgresql.string">
<span id="postgresql-string"></span><h2><a class="reference internal" href="#module-postgresql.string" title="postgresql.string"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.string</span></tt></a><a class="headerlink" href="#module-postgresql.string" title="Permalink to this headline">¶</a></h2>
<p>String split and join operations for dealing with literals and identifiers.</p>
<p>Notably, the functions in this module are intended to be used for simple
use-cases. It attempts to stay away from “real” parsing and simply provides
functions for common needs, like the ability to identify unquoted portions of a
query string so that logic or transformations can be applied to only unquoted
portions. Scanning for statement terminators, or safely interpolating
identifiers.</p>
<p>All functions deal with strict quoting rules.</p>
<dl class="function">
<dt id="postgresql.string.escape_ident">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">escape_ident</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#escape_ident"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.escape_ident" title="Permalink to this definition">¶</a></dt>
<dd><p>Replace every instance of ” with “”</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.escape_literal">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">escape_literal</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#escape_literal"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.escape_literal" title="Permalink to this definition">¶</a></dt>
<dd><p>Replace every instance of ‘ with ‘’</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.qname">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">qname</tt><big>(</big><em>*args</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#qname"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.qname" title="Permalink to this definition">¶</a></dt>
<dd><p>Quote the identifiers and join them using ‘.’</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.quote_ident">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">quote_ident</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#quote_ident"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.quote_ident" title="Permalink to this definition">¶</a></dt>
<dd><p>Replace every instance of ‘ with <em>and</em> place ‘ on each end</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.quote_ident_if_needed">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">quote_ident_if_needed</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#quote_ident_if_needed"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.quote_ident_if_needed" title="Permalink to this definition">¶</a></dt>
<dd><p>If needed, replace every instance of ‘”’ with ‘”“’ <em>and</em> place ‘”’ on each end.
Otherwise, just return the text.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.quote_literal">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">quote_literal</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#quote_literal"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.quote_literal" title="Permalink to this definition">¶</a></dt>
<dd><p>Escape the literal and wrap it in [single] quotations</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split</tt><big>(</big><em>text</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split" title="Permalink to this definition">¶</a></dt>
<dd><p>split the string up by into non-quoted and quoted portions. Zero and even
numbered indexes are unquoted portions, while odd indexes are quoted
portions.</p>
<p>Unquoted portions are regular strings, whereas quoted portions are
pair-tuples specifying the quotation mechanism and the content thereof.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="nb">list</span><span class="p">(</span><span class="n">split</span><span class="p">(</span><span class="s">"select $$foobar$$"</span><span class="p">))</span>
<span class="go">['select ', ('$$', 'foobar'), '']</span>
</pre></div>
</div>
<p>If the split ends on a quoted section, it means the string’s quote was not
terminated. Subsequently, there will be an even number of objects in the
list.</p>
<p>Quotation errors are detected, but never raised. Rather it’s up to the user
to identify the best course of action for the given split.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split_ident">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split_ident</tt><big>(</big><em>text</em>, <em>sep='</em>, <em>'</em>, <em>quote='"'</em>, <em>maxsplit=-1</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split_ident"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split_ident" title="Permalink to this definition">¶</a></dt>
<dd><p>Split a series of identifiers using the specified separator.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split_qname">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split_qname</tt><big>(</big><em>text</em>, <em>maxsplit=-1</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split_qname"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split_qname" title="Permalink to this definition">¶</a></dt>
<dd><p>Call to .split_ident() with a ‘.’ sep parameter.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split_sql">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split_sql</tt><big>(</big><em>sql</em>, <em>sep=';'</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split_sql"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split_sql" title="Permalink to this definition">¶</a></dt>
<dd><p>Given SQL, safely split using the given separator.
Notably, this yields fully split text. This should be used instead of
split_sql_str() when quoted sections need be still be isolated.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="nb">list</span><span class="p">(</span><span class="n">split_sql</span><span class="p">(</span><span class="s">'select $$1$$ AS "foo;"; select 2;'</span><span class="p">))</span>
<span class="go">[['select ', ('$$', '1'), ' AS ', ('"', 'foo;'), ''], (' select 2',), ['']]</span>
</pre></div>
</div>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split_sql_str">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split_sql_str</tt><big>(</big><em>sql</em>, <em>sep=';'</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split_sql_str"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split_sql_str" title="Permalink to this definition">¶</a></dt>
<dd><p>Identical to split_sql but yields unsplit text.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="nb">list</span><span class="p">(</span><span class="n">split_sql_str</span><span class="p">(</span><span class="s">'select $$1$$ AS "foo;"; select 2;'</span><span class="p">))</span>
<span class="go">['select $$1$$ AS "foo;"', ' select 2', '']</span>
</pre></div>
</div>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.split_using">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">split_using</tt><big>(</big><em>text</em>, <em>quote</em>, <em>sep='.'</em>, <em>maxsplit=-1</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#split_using"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.split_using" title="Permalink to this definition">¶</a></dt>
<dd><p>split the string on the seperator ignoring the separator in quoted areas.</p>
<p>This is only useful for simple quoted strings. Dollar quotes, and backslash
escapes are not supported.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.string.unsplit">
<tt class="descclassname">postgresql.string.</tt><tt class="descname">unsplit</tt><big>(</big><em>splitted_iter</em><big>)</big><a class="reference internal" href="_modules/postgresql/string.html#unsplit"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.string.unsplit" title="Permalink to this definition">¶</a></dt>
<dd><p>catenate a split string. This is needed to handle the special
cases created by pg.string.split(). (Run-away quotations, primarily)</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.exceptions">
<span id="postgresql-exceptions"></span><h2><a class="reference internal" href="#module-postgresql.exceptions" title="postgresql.exceptions"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.exceptions</span></tt></a><a class="headerlink" href="#module-postgresql.exceptions" title="Permalink to this headline">¶</a></h2>
<p>PostgreSQL exceptions and warnings with associated state codes.</p>
<p>The primary entry points of this module is the <cite>ErrorLookup</cite> function and the
<cite>WarningLookup</cite> function. Given an SQL state code, they give back the most
appropriate Error or Warning subclass.</p>
<dl class="docutils">
<dt>For more information on error codes see:</dt>
<dd><a class="reference external" href="http://www.postgresql.org/docs/current/static/errcodes-appendix.html">http://www.postgresql.org/docs/current/static/errcodes-appendix.html</a></dd>
</dl>
<p>This module is executable via -m: python -m postgresql.exceptions.
It provides a convenient way to look up the exception object mapped to by the
given error code:</p>
<div class="highlight-python"><div class="highlight"><pre>$ python -m postgresql.exceptions XX000
postgresql.exceptions.InternalError [XX000]
</pre></div>
</div>
<p>If the exact error code is not found, it will try to find the error class’s
exception(The first two characters of the error code make up the class
identity):</p>
<div class="highlight-python"><div class="highlight"><pre>$ python -m postgresql.exceptions XX400
postgresql.exceptions.InternalError [XX000]
</pre></div>
</div>
<p>If that fails, it will return <cite>postgresql.exceptions.Error</cite></p>
<dl class="exception">
<dt id="postgresql.exceptions.AuthenticationMethodError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">AuthenticationMethodError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#AuthenticationMethodError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.AuthenticationMethodError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.DriverError" title="postgresql.exceptions.DriverError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverError</span></tt></a>, <a class="reference internal" href="#postgresql.exceptions.Disconnection" title="postgresql.exceptions.Disconnection"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Disconnection</span></tt></a></p>
<p>Server requested an authentication method that is not supported by the
driver.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.CFError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">CFError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#CFError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.CFError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Configuration File Error</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.CardinalityError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">CardinalityError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#CardinalityError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.CardinalityError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Wrong number of rows returned</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ClientCannotConnectError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ClientCannotConnectError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ClientCannotConnectError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ClientCannotConnectError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ConnectionError</span></tt></p>
<p>Client was unable to establish a connection to the server.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ConnectTimeoutError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ConnectTimeoutError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ConnectTimeoutError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ConnectTimeoutError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.DriverError" title="postgresql.exceptions.DriverError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverError</span></tt></a>, <a class="reference internal" href="#postgresql.exceptions.Disconnection" title="postgresql.exceptions.Disconnection"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Disconnection</span></tt></a></p>
<p>Client was unable to esablish a connection in the given time</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ConnectionDoesNotExistError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ConnectionDoesNotExistError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ConnectionDoesNotExistError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ConnectionDoesNotExistError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ConnectionError</span></tt></p>
<p>The connection is closed or was never connected.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ConnectionFailureError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ConnectionFailureError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ConnectionFailureError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ConnectionFailureError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ConnectionError</span></tt></p>
<p>Raised when a connection is dropped</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.DPDSEError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">DPDSEError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#DPDSEError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.DPDSEError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Dependent Privilege Descriptors Still Exist</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.Disconnection">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">Disconnection</tt><a class="reference internal" href="_modules/postgresql/exceptions.html#Disconnection"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.Disconnection" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Exception" title="postgresql.exceptions.Exception"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Exception</span></tt></a></p>
<p>Exception identifying errors that result in disconnection</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.DriverError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">DriverError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#DriverError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.DriverError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Errors originating in the driver’s implementation.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.EREError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">EREError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#EREError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.EREError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>External Routine Exception</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ERIEError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ERIEError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ERIEError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ERIEError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>External Routine Invocation Exception</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.Error">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">Error</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#Error"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.Error" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.message.Message</span></tt>, <a class="reference internal" href="#postgresql.exceptions.Exception" title="postgresql.exceptions.Exception"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Exception</span></tt></a></p>
<p>A PostgreSQL Error</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.EscapeCharacterError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">EscapeCharacterError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#EscapeCharacterError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.EscapeCharacterError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DataError</span></tt></p>
<p>Invalid escape character</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.Exception">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">Exception</tt><a class="reference internal" href="_modules/postgresql/exceptions.html#Exception"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.Exception" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">builtins.Exception</span></tt></p>
<p>Base PostgreSQL exception class</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.FeatureError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">FeatureError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#FeatureError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.FeatureError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Unsupported feature</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ICVError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ICVError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ICVError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ICVError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Integrity Contraint Violation</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.IRError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">IRError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#IRError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.IRError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Insufficient Resource Error</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ITSError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ITSError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ITSError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ITSError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.TransactionError</span></tt></p>
<p>Invalid Transaction State</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.exceptions.IgnoredClientParameterWarning">
<em class="property">class </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">IgnoredClientParameterWarning</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#IgnoredClientParameterWarning"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.IgnoredClientParameterWarning" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverWarning</span></tt></p>
<p>Warn the user of a valid, but ignored parameter.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.InFailedTransactionError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">InFailedTransactionError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#InFailedTransactionError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.InFailedTransactionError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.ITSError" title="postgresql.exceptions.ITSError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ITSError</span></tt></a></p>
<p>Occurs when an action occurs in a failed transaction.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.InconsistentCursorIsolationError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">InconsistentCursorIsolationError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#InconsistentCursorIsolationError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.InconsistentCursorIsolationError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.ITSError" title="postgresql.exceptions.ITSError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ITSError</span></tt></a></p>
<p>The held cursor requires the same isolation.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.InsecurityError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">InsecurityError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#InsecurityError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.InsecurityError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.DriverError" title="postgresql.exceptions.DriverError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverError</span></tt></a>, <a class="reference internal" href="#postgresql.exceptions.Disconnection" title="postgresql.exceptions.Disconnection"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Disconnection</span></tt></a></p>
<p>Error signifying a secure channel to a server cannot be established.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.LoadError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">LoadError</tt><a class="reference internal" href="_modules/postgresql/exceptions.html#LoadError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.LoadError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Exception" title="postgresql.exceptions.Exception"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Exception</span></tt></a></p>
<p>Failed to load a library</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.OIError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">OIError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#OIError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.OIError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Operator Intervention</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ONIPSError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ONIPSError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ONIPSError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ONIPSError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Object Not In Prerequisite State</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.OperationError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">OperationError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#OperationError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.OperationError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.DriverError" title="postgresql.exceptions.DriverError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverError</span></tt></a></p>
<p>An invalid operation on an interface element.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.PLEError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">PLEError</tt><a class="reference internal" href="_modules/postgresql/exceptions.html#PLEError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.PLEError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">builtins.OverflowError</span></tt></p>
<p>Program Limit Exceeded</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.PLPGSQLError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">PLPGSQLError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#PLPGSQLError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.PLPGSQLError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Error raised by a PL/PgSQL procedural function</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.PLPGSQLRaiseError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">PLPGSQLRaiseError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#PLPGSQLRaiseError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.PLPGSQLRaiseError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.PLPGSQLError" title="postgresql.exceptions.PLPGSQLError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.PLPGSQLError</span></tt></a></p>
<p>Error raised by a PL/PgSQL RAISE statement.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ReadOnlyTransactionError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ReadOnlyTransactionError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ReadOnlyTransactionError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ReadOnlyTransactionError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.ITSError" title="postgresql.exceptions.ITSError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ITSError</span></tt></a></p>
<p>Occurs when an alteration occurs in a read-only transaction.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.SEARVError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">SEARVError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#SEARVError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.SEARVError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>Syntax Error or Access Rule Violation</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.SIOError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">SIOError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#SIOError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.SIOError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>System I/O</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.SREError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">SREError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#SREError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.SREError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>SQL Routine Exception</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.SavepointError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">SavepointError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#SavepointError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.SavepointError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.TransactionError</span></tt></p>
<p>Classification error designating errors that relate to savepoints.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.SchemaAndDataStatementsError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">SchemaAndDataStatementsError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#SchemaAndDataStatementsError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.SchemaAndDataStatementsError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.ITSError" title="postgresql.exceptions.ITSError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.ITSError</span></tt></a></p>
<p>Mixed schema and data statements not allowed.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.ServerNotReadyError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">ServerNotReadyError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#ServerNotReadyError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.ServerNotReadyError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.OIError" title="postgresql.exceptions.OIError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.OIError</span></tt></a>, <a class="reference internal" href="#postgresql.exceptions.Disconnection" title="postgresql.exceptions.Disconnection"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Disconnection</span></tt></a></p>
<p>Thrown when a connection is established to a server that is still starting up.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.TRError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">TRError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#TRError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.TRError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.TransactionError</span></tt></p>
<p>Transaction Rollback</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.exceptions.TypeConversionWarning">
<em class="property">class </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">TypeConversionWarning</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#TypeConversionWarning"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.TypeConversionWarning" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverWarning</span></tt></p>
<p>Report a potential issue with a conversion.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.exceptions.TypeIOError">
<em class="property">exception </em><tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">TypeIOError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#TypeIOError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.TypeIOError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.DriverError" title="postgresql.exceptions.DriverError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.DriverError</span></tt></a></p>
<p>Driver failed to pack or unpack a tuple.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.exceptions.map_errors_and_warnings">
<tt class="descclassname">postgresql.exceptions.</tt><tt class="descname">map_errors_and_warnings</tt><big>(</big><em>objs: "A iterable of `Warning`s and `Error`'s"</em>, <em>error_container: 'apply the code to error association to this object'={'F0000': <class 'postgresql.exceptions.CFError'></em>, <em>'': <class 'postgresql.exceptions.Error'></em>, <em>'2201F': <class 'postgresql.exceptions.PowerFunctionArgumentError'></em>, <em>'2200F': <class 'postgresql.exceptions.ZeroLengthString'></em>, <em>'22P01': <class 'postgresql.exceptions.FloatingPointError'></em>, <em>'03000': <class 'postgresql.exceptions.SQLNotYetCompleteError'></em>, <em>'22001': <class 'postgresql.exceptions.StringRightTruncationError'></em>, <em>'08003': <class 'postgresql.exceptions.ConnectionDoesNotExistError'></em>, <em>'42601': <class 'postgresql.exceptions.SyntaxError'></em>, <em>'42P11': <class 'postgresql.exceptions.CursorDefinitionError'></em>, <em>'2202E': <class 'postgresql.exceptions.ArrayElementError'></em>, <em>'22022': <class 'postgresql.exceptions.IndicatorOverflowError'></em>, <em>'55000': <class 'postgresql.exceptions.ONIPSError'></em>, <em>'25005': <class 'postgresql.exceptions.NoActiveTransactionForBranchError'></em>, <em>'0LP01': <class 'postgresql.exceptions.GrantorOperationError'></em>, <em>'25P01': <class 'postgresql.exceptions.NoActiveTransactionError'></em>, <em>'--TIO': <class 'postgresql.exceptions.TypeIOError'></em>, <em>'53200': <class 'postgresql.exceptions.MemoryError'></em>, <em>'42809': <class 'postgresql.exceptions.WrongObjectTypeError'></em>, <em>'23505': <class 'postgresql.exceptions.UniqueError'></em>, <em>'3B001': <class 'postgresql.exceptions.InvalidSavepointSpecificationError'></em>, <em>'42939': <class 'postgresql.exceptions.ReservedNameError'></em>, <em>'42P09': <class 'postgresql.exceptions.AmbiguousAliasError'></em>, <em>'27000': <class 'postgresql.exceptions.TriggeredDataChangeViolation'></em>, <em>'42710': <class 'postgresql.exceptions.DuplicateObjectError'></em>, <em>'25004': <class 'postgresql.exceptions.BadIsolationForBranchError'></em>, <em>'42830': <class 'postgresql.exceptions.ForeignKeyCreationError'></em>, <em>'22P05': <class 'postgresql.exceptions.UntranslatableCharacterError'></em>, <em>'42P15': <class 'postgresql.exceptions.SchemaDefinitionError'></em>, <em>'22025': <class 'postgresql.exceptions.EscapeSequenceError'></em>, <em>'57P03': <class 'postgresql.exceptions.ServerNotReadyError'></em>, <em>'P0003': <class 'postgresql.exceptions.PLPGSQLTooManyRowsError'></em>, <em>'08006': <class 'postgresql.exceptions.ConnectionFailureError'></em>, <em>'38003': <class 'postgresql.exceptions.ProhibitedSQLStatementError'></em>, <em>'42P17': <class 'postgresql.exceptions.ObjectDefinitionError'></em>, <em>'P0001': <class 'postgresql.exceptions.PLPGSQLRaiseError'></em>, <em>'0L000': <class 'postgresql.exceptions.GrantorError'></em>, <em>'XX000': <class 'postgresql.exceptions.InternalError'></em>, <em>'57P02': <class 'postgresql.exceptions.CrashShutdownError'></em>, <em>'2201B': <class 'postgresql.exceptions.RegularExpressionError'></em>, <em>'42701': <class 'postgresql.exceptions.DuplicateColumnError'></em>, <em>'22P03': <class 'postgresql.exceptions.BinaryRepresentationError'></em>, <em>'2F002': <class 'postgresql.exceptions.DataModificationProhibitedError'></em>, <em>'25007': <class 'postgresql.exceptions.SchemaAndDataStatementsError'></em>, <em>'22023': <class 'postgresql.exceptions.ParameterValueError'></em>, <em>'--SEC': <class 'postgresql.exceptions.InsecurityError'></em>, <em>'22005': <class 'postgresql.exceptions.AssignmentError'></em>, <em>'42725': <class 'postgresql.exceptions.AmbiguousFunctionError'></em>, <em>'42P19': <class 'postgresql.exceptions.RecursionError'></em>, <em>'22P02': <class 'postgresql.exceptions.TextRepresentationError'></em>, <em>'40000': <class 'postgresql.exceptions.TRError'></em>, <em>'09000': <class 'postgresql.exceptions.TriggeredActionError'></em>, <em>'22012': <class 'postgresql.exceptions.ZeroDivisionError'></em>, <em>'53000': <class 'postgresql.exceptions.IRError'></em>, <em>'22018': <class 'postgresql.exceptions.CastCharacterValueError'></em>, <em>'23514': <class 'postgresql.exceptions.CheckError'></em>, <em>'XX002': <class 'postgresql.exceptions.IndexCorruptedError'></em>, <em>'23001': <class 'postgresql.exceptions.RestrictError'></em>, <em>'39001': <class 'postgresql.exceptions.InvalidSQLState'></em>, <em>'--000': <class 'postgresql.exceptions.DriverError'></em>, <em>'2200M': <class 'postgresql.exceptions.XMLDocumentError'></em>, <em>'2D000': <class 'postgresql.exceptions.TransactionTerminationError'></em>, <em>'42611': <class 'postgresql.exceptions.ColumnDefinitionError'></em>, <em>'42P12': <class 'postgresql.exceptions.DatabaseDefinitionError'></em>, <em>'40P01': <class 'postgresql.exceptions.DeadlockError'></em>, <em>'42602': <class 'postgresql.exceptions.SEARVNameError'></em>, <em>'25001': <class 'postgresql.exceptions.ActiveTransactionError'></em>, <em>'2200G': <class 'postgresql.exceptions.SpecificTypeMismatch'></em>, <em>'57014': <class 'postgresql.exceptions.QueryCanceledError'></em>, <em>'2BP01': <class 'postgresql.exceptions.DPDSEObjectError'></em>, <em>'38002': <class 'postgresql.exceptions.ModifyingSQLDataNotPermittedError'></em>, <em>'--cIO': <class 'postgresql.exceptions.CompositeError'></em>, <em>'08004': <class 'postgresql.exceptions.ConnectionRejectionError'></em>, <em>'22027': <class 'postgresql.exceptions.TrimError'></em>, <em>'42804': <class 'postgresql.exceptions.TypeMismatchError'></em>, <em>'42501': <class 'postgresql.exceptions.InsufficientPrivilegeError'></em>, <em>'23502': <class 'postgresql.exceptions.NotNullError'></em>, <em>'22P04': <class 'postgresql.exceptions.BadCopyError'></em>, <em>'39P02': <class 'postgresql.exceptions.SRFProtocolError'></em>, <em>'22020': <class 'postgresql.exceptions.LimitValueError'></em>, <em>'P0002': <class 'postgresql.exceptions.PLPGSQLNoDataFoundError'></em>, <em>'F0001': <class 'postgresql.exceptions.LockFileExistsError'></em>, <em>'2200D': <class 'postgresql.exceptions.EscapeOctetError'></em>, <em>'42712': <class 'postgresql.exceptions.DuplicateAliasError'></em>, <em>'42P16': <class 'postgresql.exceptions.TableDefinitionError'></em>, <em>'55P02': <class 'postgresql.exceptions.ImmutableRuntimeParameterError'></em>, <em>'--PIO': <class 'postgresql.exceptions.ParameterError'></em>, <em>'42703': <class 'postgresql.exceptions.UndefinedColumnError'></em>, <em>'42P13': <class 'postgresql.exceptions.FunctionDefinitionError'></em>, <em>'P0000': <class 'postgresql.exceptions.PLPGSQLError'></em>, <em>'2F000': <class 'postgresql.exceptions.SREError'></em>, <em>'42P06': <class 'postgresql.exceptions.DuplicateSchemaError'></em>, <em>'2201G': <class 'postgresql.exceptions.WidthBucketFunctionArgumentError'></em>, <em>'XX001': <class 'postgresql.exceptions.DataCorruptedError'></em>, <em>'--TOE': <class 'postgresql.exceptions.ConnectTimeoutError'></em>, <em>'58000': <class 'postgresql.exceptions.SIOError'></em>, <em>'2F004': <class 'postgresql.exceptions.ReadingDataProhibitedError'></em>, <em>'42P20': <class 'postgresql.exceptions.WindowError'></em>, <em>'42P08': <class 'postgresql.exceptions.AmbiguousParameterError'></em>, <em>'42P10': <class 'postgresql.exceptions.ColumnReferenceError'></em>, <em>'2200S': <class 'postgresql.exceptions.XMLCommentError'></em>, <em>'42846': <class 'postgresql.exceptions.CoercionError'></em>, <em>'42P02': <class 'postgresql.exceptions.UndefinedParameterError'></em>, <em>'25002': <class 'postgresql.exceptions.BranchAlreadyActiveError'></em>, <em>'22011': <class 'postgresql.exceptions.SubstringError'></em>, <em>'53100': <class 'postgresql.exceptions.DiskFullError'></em>, <em>'44000': <class 'postgresql.exceptions.WithCheckOptionError'></em>, <em>'42P14': <class 'postgresql.exceptions.PreparedStatementDefinitionError'></em>, <em>'57000': <class 'postgresql.exceptions.OIError'></em>, <em>'55006': <class 'postgresql.exceptions.ObjectInUseError'></em>, <em>'28000': <class 'postgresql.exceptions.AuthenticationSpecificationError'></em>, <em>'2200N': <class 'postgresql.exceptions.XMLContentError'></em>, <em>'42723': <class 'postgresql.exceptions.DuplicateFunctionError'></em>, <em>'2200L': <class 'postgresql.exceptions.NotXMLError'></em>, <em>'25003': <class 'postgresql.exceptions.BadAccessModeForBranchError'></em>, <em>'58P01': <class 'postgresql.exceptions.UndefinedFileError'></em>, <em>'08001': <class 'postgresql.exceptions.ClientCannotConnectError'></em>, <em>'40001': <class 'postgresql.exceptions.SerializationError'></em>, <em>'2B000': <class 'postgresql.exceptions.DPDSEError'></em>, <em>'22004': <class 'postgresql.exceptions.NullValueNotAllowedError'></em>, <em>'42P04': <class 'postgresql.exceptions.DuplicateDatabaseError'></em>, <em>'22000': <class 'postgresql.exceptions.DataError'></em>, <em>'55P03': <class 'postgresql.exceptions.UnavailableLockError'></em>, <em>'2201W': <class 'postgresql.exceptions.LimitValueError'></em>, <em>'23000': <class 'postgresql.exceptions.ICVError'></em>, <em>'--OPE': <class 'postgresql.exceptions.OperationError'></em>, <em>'26000': <class 'postgresql.exceptions.StatementNameError'></em>, <em>'22024': <class 'postgresql.exceptions.UnterminatedCStringError'></em>, <em>'22026': <class 'postgresql.exceptions.StringDataLengthError'></em>, <em>'40002': <class 'postgresql.exceptions.IntegrityConstraintViolationError'></em>, <em>'25006': <class 'postgresql.exceptions.ReadOnlyTransactionError'></em>, <em>'22021': <class 'postgresql.exceptions.EncodingError'></em>, <em>'42P07': <class 'postgresql.exceptions.DuplicateTableError'></em>, <em>'--AUT': <class 'postgresql.exceptions.AuthenticationMethodError'></em>, <em>'08P01': <class 'postgresql.exceptions.ProtocolError'></em>, <em>'24000': <class 'postgresql.exceptions.CursorStateError'></em>, <em>'42P03': <class 'postgresql.exceptions.DuplicateCursorError'></em>, <em>'22P06': <class 'postgresql.exceptions.NonstandardUseOfEscapeCharacterError'></em>, <em>'22009': <class 'postgresql.exceptions.TimeZoneDisplacementValueError'></em>, <em>'2F003': <class 'postgresql.exceptions.StatementProhibitedError'></em>, <em>'53300': <class 'postgresql.exceptions.TooManyConnectionsError'></em>, <em>'22007': <class 'postgresql.exceptions.DateTimeFormatError'></em>, <em>'2201X': <class 'postgresql.exceptions.OffsetValueError'></em>, <em>'42000': <class 'postgresql.exceptions.SEARVError'></em>, <em>'22002': <class 'postgresql.exceptions.NullValueNoIndicatorParameter'></em>, <em>'42622': <class 'postgresql.exceptions.NameTooLongError'></em>, <em>'0F001': <class 'postgresql.exceptions.LocatorSpecificationError'></em>, <em>'39000': <class 'postgresql.exceptions.ERIEError'></em>, <em>'08007': <class 'postgresql.exceptions.TransactionResolutionUnknownError'></em>, <em>'08000': <class 'postgresql.exceptions.ConnectionError'></em>, <em>'20000': <class 'postgresql.exceptions.CaseNotFoundError'></em>, <em>'2200B': <class 'postgresql.exceptions.EscapeCharacterConflictError'></em>, <em>'0B000': <class 'postgresql.exceptions.TransactionInitiationError'></em>, <em>'22008': <class 'postgresql.exceptions.DateTimeFieldOverflowError'></em>, <em>'21000': <class 'postgresql.exceptions.CardinalityError'></em>, <em>'38001': <class 'postgresql.exceptions.ContainingSQLNotPermittedError'></em>, <em>'2200T': <class 'postgresql.exceptions.XMLProcessingInstructionError'></em>, <em>'0F000': <class 'postgresql.exceptions.LocatorError'></em>, <em>'0A000': <class 'postgresql.exceptions.FeatureError'></em>, <em>'42704': <class 'postgresql.exceptions.UndefinedObjectError'></em>, <em>'25P02': <class 'postgresql.exceptions.InFailedTransactionError'></em>, <em>'57P01': <class 'postgresql.exceptions.AdminShutdownError'></em>, <em>'58P02': <class 'postgresql.exceptions.DuplicateFileError'></em>, <em>'25008': <class 'postgresql.exceptions.InconsistentCursorIsolationError'></em>, <em>'42702': <class 'postgresql.exceptions.AmbiguousColumnError'></em>, <em>'22015': <class 'postgresql.exceptions.IntervalFieldOverflowError'></em>, <em>'--CIO': <class 'postgresql.exceptions.ColumnError'></em>, <em>'2F005': <class 'postgresql.exceptions.FunctionExecutedNoReturnStatementError'></em>, <em>'38004': <class 'postgresql.exceptions.ReadingSQLDataNotPermittedError'></em>, <em>'22010': <class 'postgresql.exceptions.IndicatorParameterValueError'></em>, <em>'23503': <class 'postgresql.exceptions.ForeignKeyError'></em>, <em>'39P01': <class 'postgresql.exceptions.TriggerProtocolError'></em>, <em>'40003': <class 'postgresql.exceptions.StatementCompletionUnknownError'></em>, <em>'25000': <class 'postgresql.exceptions.ITSError'></em>, <em>'42P01': <class 'postgresql.exceptions.UndefinedTableError'></em>, <em>'42803': <class 'postgresql.exceptions.GroupingError'></em>, <em>'38000': <class 'postgresql.exceptions.EREError'></em>, <em>'42P18': <class 'postgresql.exceptions.IndeterminateTypeError'></em>, <em>'3F000': <class 'postgresql.exceptions.SchemaNameError'></em>, <em>'42883': <class 'postgresql.exceptions.UndefinedFunctionError'></em>, <em>'2201E': <class 'postgresql.exceptions.LogArgumentError'></em>, <em>'2200C': <class 'postgresql.exceptions.EscapeCharacterError'></em>, <em>'3B000': <class 'postgresql.exceptions.SavepointError'></em>, <em>'42P05': <class 'postgresql.exceptions.DuplicatePreparedStatementError'></em>, <em>'0P000': <class 'postgresql.exceptions.RoleSpecificationError'></em>, <em>'3D000': <class 'postgresql.exceptions.CatalogNameError'></em>, <em>'22003': <class 'postgresql.exceptions.NumericRangeError'></em>, <em>'34000': <class 'postgresql.exceptions.CursorNameError'></em>, <em>'39004': <class 'postgresql.exceptions.NullValueNotAllowed'>}</em>, <em>warning_container: 'apply the code to warning association to this object'={'01P01': <class 'postgresql.exceptions.DeprecationWarning'></em>, <em>'01004': <class 'postgresql.exceptions.StringDataRightTruncationWarning'></em>, <em>'01-CP': <class 'postgresql.exceptions.IgnoredClientParameterWarning'></em>, <em>'01003': <class 'postgresql.exceptions.NullValueEliminatedInSetFunctionWarning'></em>, <em>'01-TP': <class 'postgresql.exceptions.TypeConversionWarning'></em>, <em>'02000': <class 'postgresql.exceptions.NoDataWarning'></em>, <em>'01008': <class 'postgresql.exceptions.ImplicitZeroBitPaddingWarning'></em>, <em>'01-00': <class 'postgresql.exceptions.DriverWarning'></em>, <em>'02001': <class 'postgresql.exceptions.NoMoreSetsReturned'></em>, <em>'0100C': <class 'postgresql.exceptions.DynamicResultSetsReturnedWarning'></em>, <em>'01007': <class 'postgresql.exceptions.PrivilegeNotGrantedWarning'></em>, <em>'01006': <class 'postgresql.exceptions.PrivilegeNotRevokedWarning'></em>, <em>'01000': <class 'postgresql.exceptions.Warning'>}</em><big>)</big><a class="reference internal" href="_modules/postgresql/exceptions.html#map_errors_and_warnings"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.exceptions.map_errors_and_warnings" title="Permalink to this definition">¶</a></dt>
<dd><p>Construct the code-to-error and code-to-warning associations.</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.temporal">
<span id="postgresql-temporal"></span><h2><a class="reference internal" href="#module-postgresql.temporal" title="postgresql.temporal"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.temporal</span></tt></a><a class="headerlink" href="#module-postgresql.temporal" title="Permalink to this headline">¶</a></h2>
<p>Temporary PostgreSQL cluster for the process.</p>
<dl class="class">
<dt id="postgresql.temporal.Temporal">
<em class="property">class </em><tt class="descclassname">postgresql.temporal.</tt><tt class="descname">Temporal</tt><a class="reference internal" href="_modules/postgresql/temporal.html#Temporal"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.temporal.Temporal" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">builtins.object</span></tt></p>
<p>Manages a temporary cluster for the duration of the process.</p>
<p>Instances of this class reference a distinct cluster. These clusters are
transient; they will only exist until the process exits.</p>
<p>Usage:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="kn">from</span> <span class="nn">postgresql.temporal</span> <span class="kn">import</span> <span class="n">pg_tmp</span>
<span class="gp">>>> </span><span class="k">with</span> <span class="n">pg_tmp</span><span class="p">:</span>
<span class="gp">... </span> <span class="n">ps</span> <span class="o">=</span> <span class="n">db</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="s">'SELECT 1'</span><span class="p">)</span>
<span class="gp">... </span> <span class="k">assert</span> <span class="n">ps</span><span class="o">.</span><span class="n">first</span><span class="p">()</span> <span class="o">==</span> <span class="mi">1</span>
</pre></div>
</div>
<p>Or <cite>pg_tmp</cite> can decorate a method or function.</p>
<dl class="method">
<dt id="postgresql.temporal.Temporal.cluster_dirname">
<tt class="descname">cluster_dirname</tt><big>(</big><big>)</big><a class="headerlink" href="#postgresql.temporal.Temporal.cluster_dirname" title="Permalink to this definition">¶</a></dt>
<dd><p>Format the cluster directory name.</p>
</dd></dl>
</dd></dl>
<dl class="data">
<dt id="postgresql.temporal.pg_tmp">
<tt class="descclassname">postgresql.temporal.</tt><tt class="descname">pg_tmp</tt><em class="property"> = <postgresql.temporal.Temporal object at 0x2b06ae0198d0></em><a class="headerlink" href="#postgresql.temporal.pg_tmp" title="Permalink to this definition">¶</a></dt>
<dd><p>The process’ temporary cluster.</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.installation">
<span id="postgresql-installation"></span><h2><a class="reference internal" href="#module-postgresql.installation" title="postgresql.installation"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.installation</span></tt></a><a class="headerlink" href="#module-postgresql.installation" title="Permalink to this headline">¶</a></h2>
<p>Collect and access PostgreSQL installation information.</p>
<dl class="class">
<dt id="postgresql.installation.Installation">
<em class="property">class </em><tt class="descclassname">postgresql.installation.</tt><tt class="descname">Installation</tt><big>(</big><em>info: dict</em><big>)</big><a class="reference internal" href="_modules/postgresql/installation.html#Installation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.installation.Installation" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.api.Installation" title="postgresql.api.Installation"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.api.Installation</span></tt></a></p>
<p>Class providing a Python interface to PostgreSQL installation information.</p>
<dl class="attribute">
<dt id="postgresql.installation.Installation.info">
<tt class="descname">info</tt><em class="property"> = None</em><a class="headerlink" href="#postgresql.installation.Installation.info" title="Permalink to this definition">¶</a></dt>
<dd><p>The pg_config information dictionary.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.installation.Installation.ssl">
<tt class="descname">ssl</tt><a class="reference internal" href="_modules/postgresql/installation.html#Installation.ssl"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.installation.Installation.ssl" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether the installation was compiled with SSL support.</p>
</dd></dl>
</dd></dl>
<dl class="function">
<dt id="postgresql.installation.default">
<tt class="descclassname">postgresql.installation.</tt><tt class="descname">default</tt><big>(</big><em>typ=<class 'postgresql.installation.Installation'></em><big>)</big><a class="reference internal" href="_modules/postgresql/installation.html#default"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.installation.default" title="Permalink to this definition">¶</a></dt>
<dd><p>Get the default Installation.</p>
<p>Uses default_pg_config() to identify the executable.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.installation.default_pg_config">
<tt class="descclassname">postgresql.installation.</tt><tt class="descname">default_pg_config</tt><big>(</big><em>execname='pg_config'</em>, <em>envkey='PGINSTALLATION'</em><big>)</big><a class="reference internal" href="_modules/postgresql/installation.html#default_pg_config"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.installation.default_pg_config" title="Permalink to this definition">¶</a></dt>
<dd><p>Get the default <cite>pg_config</cite> executable on the system.</p>
<p>If ‘PGINSTALLATION’ is in the environment, use it.
Otherwise, look through the system’s PATH environment.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.installation.pg_config_dictionary">
<tt class="descclassname">postgresql.installation.</tt><tt class="descname">pg_config_dictionary</tt><big>(</big><em>*pg_config_path</em><big>)</big><a class="reference internal" href="_modules/postgresql/installation.html#pg_config_dictionary"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.installation.pg_config_dictionary" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a dictionary of the information available in the given
pg_config_path. This provides a one-shot solution to fetching information
from the pg_config binary. Returns a dictionary object.</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.cluster">
<span id="postgresql-cluster"></span><h2><a class="reference internal" href="#module-postgresql.cluster" title="postgresql.cluster"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.cluster</span></tt></a><a class="headerlink" href="#module-postgresql.cluster" title="Permalink to this headline">¶</a></h2>
<p>Create, control, and destroy PostgreSQL clusters.</p>
<p>postgresql.cluster provides a programmer’s interface to controlling a PostgreSQL
cluster. It provides direct access to proper signalling interfaces.</p>
<dl class="class">
<dt id="postgresql.cluster.Cluster">
<em class="property">class </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">Cluster</tt><big>(</big><em>installation: 'installation object'</em>, <em>data_directory: 'path to the data directory'</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.api.Cluster" title="postgresql.api.Cluster"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.api.Cluster</span></tt></a></p>
<p>Interface to a PostgreSQL cluster.</p>
<p>Provides mechanisms to start, stop, restart, kill, drop, and initalize a
cluster(data directory).</p>
<p>Cluster does not strive to be consistent with <tt class="docutils literal"><span class="pre">pg_ctl</span></tt>. This is considered
to be a base class for managing a cluster, and is intended to be extended to
accommodate for a particular purpose.</p>
<dl class="method">
<dt id="postgresql.cluster.Cluster.address">
<tt class="descname">address</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.address"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.address" title="Permalink to this definition">¶</a></dt>
<dd><p>Get the host-port pair from the configuration.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.connect">
<tt class="descname">connect</tt><big>(</big><em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.connect"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.connect" title="Permalink to this definition">¶</a></dt>
<dd><p>Create an established connection from the connector.</p>
<p>Cluster must be running.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.connection">
<tt class="descname">connection</tt><big>(</big><em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.connection"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.connection" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a connection object to the cluster, but do not connect.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.connector">
<tt class="descname">connector</tt><big>(</big><em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.connector"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.connector" title="Permalink to this definition">¶</a></dt>
<dd><p>Create a postgresql.driver connector based on the given keywords and
listen_addresses and port configuration in settings.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.cluster.Cluster.daemon_path">
<tt class="descname">daemon_path</tt><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.daemon_path"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.daemon_path" title="Permalink to this definition">¶</a></dt>
<dd><p>Path to the executable to use to startup the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.drop">
<tt class="descname">drop</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.drop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.drop" title="Permalink to this definition">¶</a></dt>
<dd><p>Stop the cluster and remove it from the filesystem</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.get_pid_from_file">
<tt class="descname">get_pid_from_file</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.get_pid_from_file"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.get_pid_from_file" title="Permalink to this definition">¶</a></dt>
<dd><p>The current pid from the postmaster.pid file.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.cluster.Cluster.hba_file">
<tt class="descname">hba_file</tt><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.hba_file"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.hba_file" title="Permalink to this definition">¶</a></dt>
<dd><p>The path to the HBA file of the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.init">
<tt class="descname">init</tt><big>(</big><em>password: "Password to assign to the cluster's superuser(`user` keyword)."=None</em>, <em>**kw</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.init"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.init" title="Permalink to this definition">¶</a></dt>
<dd><p>Create the cluster at the given <cite>data_directory</cite> using the
provided keyword parameters as options to the command.</p>
<p><cite>command_option_map</cite> provides the mapping of keyword arguments
to command options.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.initialized">
<tt class="descname">initialized</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.initialized"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.initialized" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether or not the data directory <em>appears</em> to be a valid cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.kill">
<tt class="descname">kill</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.kill"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.kill" title="Permalink to this definition">¶</a></dt>
<dd><p>Stop the cluster immediately(SIGKILL).</p>
<p>Does <em>not</em> wait for shutdown.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.cluster.Cluster.pid">
<tt class="descname">pid</tt><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.pid"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.pid" title="Permalink to this definition">¶</a></dt>
<dd><p>If we have the subprocess, use the pid on the object.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.ready_for_connections">
<tt class="descname">ready_for_connections</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.ready_for_connections"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.ready_for_connections" title="Permalink to this definition">¶</a></dt>
<dd><p>If the daemon is running, and is not in startup mode.</p>
<p>This only works for clusters configured for TCP/IP connections.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.reload">
<tt class="descname">reload</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.reload"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.reload" title="Permalink to this definition">¶</a></dt>
<dd><p>Signal the cluster to reload its configuration file.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.restart">
<tt class="descname">restart</tt><big>(</big><em>logfile=None</em>, <em>settings=None</em>, <em>timeout=10</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.restart"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.restart" title="Permalink to this definition">¶</a></dt>
<dd><p>Restart the cluster gracefully.</p>
<p>This provides a higher level interface to stopping then starting the
cluster. It will perform the wait operations and block until the
restart is complete.</p>
<p>If waiting is not desired, .start() and .stop() should be used directly.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.running">
<tt class="descname">running</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.running"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.running" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether or not the postmaster is running.</p>
<p>This does <em>not</em> mean the cluster is accepting connections.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.shutdown">
<tt class="descname">shutdown</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.shutdown"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.shutdown" title="Permalink to this definition">¶</a></dt>
<dd><p>Shutdown the cluster as soon as possible, disconnecting clients.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.start">
<tt class="descname">start</tt><big>(</big><em>logfile: 'Where to send stderr'=None</em>, <em>settings: 'Mapping of runtime parameters'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.start" title="Permalink to this definition">¶</a></dt>
<dd><p>Start the cluster.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.stop">
<tt class="descname">stop</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.stop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.stop" title="Permalink to this definition">¶</a></dt>
<dd><p>Stop the cluster gracefully waiting for clients to disconnect(SIGTERM).</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.wait_until_started">
<tt class="descname">wait_until_started</tt><big>(</big><em>timeout: 'how long to wait before throwing a timeout exception'=10</em>, <em>delay: 'how long to sleep before re-testing'=0.05</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.wait_until_started"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.wait_until_started" title="Permalink to this definition">¶</a></dt>
<dd><p>After the <cite>start</cite> method is used, this can be ran in order to block
until the cluster is ready for use.</p>
<p>This method loops until <cite>ready_for_connections</cite> returns <cite>True</cite> in
order to make sure that the cluster is actually up.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.cluster.Cluster.wait_until_stopped">
<tt class="descname">wait_until_stopped</tt><big>(</big><em>timeout: 'how long to wait before throwing a timeout exception'=10</em>, <em>delay: 'how long to sleep before re-testing'=0.05</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#Cluster.wait_until_stopped"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.Cluster.wait_until_stopped" title="Permalink to this definition">¶</a></dt>
<dd><p>After the <cite>stop</cite> method is used, this can be ran in order to block until
the cluster is shutdown.</p>
<p>Additionally, catching <cite>ClusterTimeoutError</cite> exceptions would be a
starting point for making decisions about whether or not to issue a kill
to the daemon.</p>
</dd></dl>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.ClusterError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.exceptions.Error" title="postgresql.exceptions.Error"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Error</span></tt></a></p>
<p>General cluster error.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.ClusterInitializationError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterInitializationError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterInitializationError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterInitializationError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.cluster.ClusterError" title="postgresql.cluster.ClusterError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.cluster.ClusterError</span></tt></a></p>
<p>General cluster initialization failure</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.ClusterNotRunningError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterNotRunningError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterNotRunningError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterNotRunningError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.cluster.ClusterError" title="postgresql.cluster.ClusterError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.cluster.ClusterError</span></tt></a></p>
<p>Cluster is not running</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.ClusterStartupError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterStartupError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterStartupError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterStartupError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.cluster.ClusterError" title="postgresql.cluster.ClusterError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.cluster.ClusterError</span></tt></a></p>
<p>Cluster startup failed</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.ClusterTimeoutError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterTimeoutError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterTimeoutError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterTimeoutError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.cluster.ClusterError" title="postgresql.cluster.ClusterError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.cluster.ClusterError</span></tt></a></p>
<p>Cluster operation timed out</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.cluster.ClusterWarning">
<em class="property">class </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">ClusterWarning</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#ClusterWarning"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.ClusterWarning" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.exceptions.Warning</span></tt></p>
<p>Warning issued by cluster operations</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.cluster.InitDBError">
<em class="property">exception </em><tt class="descclassname">postgresql.cluster.</tt><tt class="descname">InitDBError</tt><big>(</big><em>message: 'The primary information of the message'</em>, <em>code: 'Message code to attach (SQL state)'=None</em>, <em>details: 'additional information associated with the message'={}</em>, <em>source: 'Which side generated the message(SERVER</em>, <em>CLIENT)'=None</em>, <em>creator: 'The interface element that called for instantiation'=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/cluster.html#InitDBError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.cluster.InitDBError" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="#postgresql.cluster.ClusterInitializationError" title="postgresql.cluster.ClusterInitializationError"><tt class="xref py py-class docutils literal"><span class="pre">postgresql.cluster.ClusterInitializationError</span></tt></a></p>
<p>A non-zero result was returned by the initdb command</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.copyman">
<span id="postgresql-copyman"></span><h2><a class="reference internal" href="#module-postgresql.copyman" title="postgresql.copyman"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.copyman</span></tt></a><a class="headerlink" href="#module-postgresql.copyman" title="Permalink to this headline">¶</a></h2>
<p>Manage complex COPY operations; one-to-many COPY streaming.</p>
<p>Primarily this module houses the <cite>CopyManager</cite> class, and the <cite>transfer</cite>
function for a high-level interface to using the <cite>CopyManager</cite>.</p>
<dl class="class">
<dt id="postgresql.copyman.CallReceiver">
<em class="property">class </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">CallReceiver</tt><big>(</big><em>callable</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#CallReceiver"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.CallReceiver" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.copyman.Receiver</span></tt></p>
<p>Call the given object with a list of COPY lines.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.copyman.CopyFail">
<em class="property">exception </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">CopyFail</tt><big>(</big><em>manager</em>, <em>reason=None</em>, <em>receiver_faults=None</em>, <em>producer_fault=None</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#CopyFail"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.CopyFail" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">builtins.Exception</span></tt></p>
<p>Exception thrown by the CopyManager when the COPY operation failed.</p>
<p>The ‘manager’ attribute the CopyManager that raised the CopyFail.</p>
<p>The ‘reason’ attribute is a string indicating why it failed.</p>
<p>The ‘receiver_faults’ attribute is a mapping of receivers to exceptions that were
raised on exit.</p>
<p>The ‘producer_fault’ attribute specifies if the producer raise an exception
on exit.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.copyman.CopyManager">
<em class="property">class </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">CopyManager</tt><big>(</big><em>producer</em>, <em>*receivers</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#CopyManager"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.CopyManager" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt>, <tt class="xref py py-class docutils literal"><span class="pre">collections.abc.Iterator</span></tt></p>
<p>A class for managing COPY operations.</p>
<p>Connects the producer to the receivers.</p>
<dl class="method">
<dt id="postgresql.copyman.CopyManager.reconcile">
<tt class="descname">reconcile</tt><big>(</big><em>r</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#CopyManager.reconcile"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.CopyManager.reconcile" title="Permalink to this definition">¶</a></dt>
<dd><p>Reconcile a receiver that faulted.</p>
<p>This method should be used to add back a receiver that failed to
complete its write operation, but is capable of completing the
operation at this time.</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="postgresql.copyman.NullProducer">
<em class="property">class </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">NullProducer</tt><a class="reference internal" href="_modules/postgresql/copyman.html#NullProducer"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.NullProducer" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.copyman.Producer</span></tt></p>
<p>Produces no copy data.</p>
</dd></dl>
<dl class="exception">
<dt id="postgresql.copyman.ProducerFault">
<em class="property">exception </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">ProducerFault</tt><big>(</big><em>manager</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#ProducerFault"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.ProducerFault" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.copyman.Fault</span></tt></p>
<p>Exception raised when the Producer caused an exception.</p>
<p>Normally, Producer faults are fatal.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.copyman.ProtocolProducer">
<em class="property">class </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">ProtocolProducer</tt><big>(</big><em>recv_into: 'callable taking writable buffer and size'</em>, <em>buffer_size=10240</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#ProtocolProducer"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.ProtocolProducer" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.copyman.Producer</span></tt></p>
<p>Producer using a PQv3 data stream.</p>
<p>Normally, this class needs to be subclassed as it assumes that the given
recv_into function will write COPY messages.</p>
<dl class="method">
<dt id="postgresql.copyman.ProtocolProducer.recover">
<tt class="descname">recover</tt><big>(</big><em>view</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#ProtocolProducer.recover"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.ProtocolProducer.recover" title="Permalink to this definition">¶</a></dt>
<dd><p>Given a view containing data read from the wire, recover the
controller’s state.</p>
<p>This needs to be implemented by subclasses in order for the
ProtocolReceiver to pass control back to the original state machine.</p>
</dd></dl>
</dd></dl>
<dl class="exception">
<dt id="postgresql.copyman.ReceiverFault">
<em class="property">exception </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">ReceiverFault</tt><big>(</big><em>manager</em>, <em>faults</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#ReceiverFault"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.ReceiverFault" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.copyman.Fault</span></tt></p>
<p>Exception raised when Receivers cause an exception.</p>
<p>Faults should be trapped if recovery from an exception is
possible, or if the failed receiver is optional to the succes of the
operation.</p>
<p>The ‘manager’ attribute is the CopyManager that raised the fault.</p>
<p>The ‘faults’ attribute is a dictionary mapping the receiver to the exception
instance raised.</p>
</dd></dl>
<dl class="class">
<dt id="postgresql.copyman.WireState">
<em class="property">class </em><tt class="descclassname">postgresql.copyman.</tt><tt class="descname">WireState</tt><big>(</big><em>condition=<method-wrapper '__ne__' of int object at 0x9f9520></em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#WireState"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.WireState" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">builtins.object</span></tt></p>
<p>Manages the state of the wire.</p>
<p>This class manages three possible positions:</p>
<blockquote>
<div><ol class="arabic simple">
<li>Between wire messages</li>
<li>Inside message header</li>
<li>Inside message (with complete header)</li>
</ol>
</div></blockquote>
<p>The wire state will become unusable when the configured condition is True.</p>
<dl class="method">
<dt id="postgresql.copyman.WireState.update">
<tt class="descname">update</tt><big>(</big><em>view</em>, <em>getlen=<function mk_pack.<locals>.unpack at 0x2b06ae08bd90></em>, <em>len=<built-in function len></em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#WireState.update"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.WireState.update" title="Permalink to this definition">¶</a></dt>
<dd><p>Given the state of the COPY and new data, advance the position on the
COPY stream.</p>
</dd></dl>
</dd></dl>
<dl class="data">
<dt id="postgresql.copyman.default_buffer_size">
<tt class="descclassname">postgresql.copyman.</tt><tt class="descname">default_buffer_size</tt><em class="property"> = 10240</em><a class="headerlink" href="#postgresql.copyman.default_buffer_size" title="Permalink to this definition">¶</a></dt>
<dd><p>10KB buffer for COPY messages by default.</p>
</dd></dl>
<dl class="function">
<dt id="postgresql.copyman.transfer">
<tt class="descclassname">postgresql.copyman.</tt><tt class="descname">transfer</tt><big>(</big><em>producer</em>, <em>*receivers</em><big>)</big><a class="reference internal" href="_modules/postgresql/copyman.html#transfer"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.copyman.transfer" title="Permalink to this definition">¶</a></dt>
<dd><p>Perform a COPY operation using the given statements:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">>>> </span><span class="kn">import</span> <span class="nn">copyman</span>
<span class="gp">>>> </span><span class="n">copyman</span><span class="o">.</span><span class="n">transfer</span><span class="p">(</span><span class="n">src</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="s">"COPY table TO STDOUT"</span><span class="p">),</span> <span class="n">dst</span><span class="o">.</span><span class="n">prepare</span><span class="p">(</span><span class="s">"COPY table FROM STDIN"</span><span class="p">))</span>
</pre></div>
</div>
</dd></dl>
<dl class="function">
<dt id="postgresql.copyman.ulong_pack">
<tt class="descclassname">postgresql.copyman.</tt><tt class="descname">ulong_pack</tt><big>(</big><big>)</big><a class="headerlink" href="#postgresql.copyman.ulong_pack" title="Permalink to this definition">¶</a></dt>
<dd><p>S.pack(v1, v2, ...) -> bytes</p>
<p>Return a bytes object containing values v1, v2, ... packed according
to the format string S.format. See help(struct) for more on format
strings.</p>
</dd></dl>
</div>
<div class="section" id="module-postgresql.alock">
<span id="postgresql-alock"></span><h2><a class="reference internal" href="#module-postgresql.alock" title="postgresql.alock"><tt class="xref py py-mod docutils literal"><span class="pre">postgresql.alock</span></tt></a><a class="headerlink" href="#module-postgresql.alock" title="Permalink to this headline">¶</a></h2>
<p>Tools for Advisory Locks</p>
<dl class="class">
<dt id="postgresql.alock.ALock">
<em class="property">class </em><tt class="descclassname">postgresql.alock.</tt><tt class="descname">ALock</tt><big>(</big><em>database</em>, <em>*identifiers</em><big>)</big><a class="reference internal" href="_modules/postgresql/alock.html#ALock"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.alock.ALock" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <tt class="xref py py-class docutils literal"><span class="pre">postgresql.python.element.Element</span></tt></p>
<p>Advisory Lock class for managing the acquisition and release of a sequence
of PostgreSQL advisory locks.</p>
<p>ALock()’s are fairly consistent with threading.RLock()’s. They can be
acquired multiple times, and they must be released the same number of times
for the lock to actually be released.</p>
<p>A notably difference is that ALock’s manage a sequence of lock identifiers.
This means that a given ALock() may represent multiple advisory locks.</p>
<dl class="method">
<dt id="postgresql.alock.ALock.acquire">
<tt class="descname">acquire</tt><big>(</big><em>blocking=True</em>, <em>len=<built-in function len></em><big>)</big><a class="reference internal" href="_modules/postgresql/alock.html#ALock.acquire"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.alock.ALock.acquire" title="Permalink to this definition">¶</a></dt>
<dd><p>Acquire the locks using the configured identifiers.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.alock.ALock.locked">
<tt class="descname">locked</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/alock.html#ALock.locked"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.alock.ALock.locked" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether the locks have been acquired. This method is sensitive to the
connection’s state. If the connection is closed, it will return False.</p>
</dd></dl>
<dl class="attribute">
<dt id="postgresql.alock.ALock.mode">
<tt class="descname">mode</tt><a class="reference internal" href="_modules/postgresql/alock.html#ALock.mode"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.alock.ALock.mode" title="Permalink to this definition">¶</a></dt>
<dd><p>The mode of the lock class.</p>
</dd></dl>
<dl class="method">
<dt id="postgresql.alock.ALock.release">
<tt class="descname">release</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/postgresql/alock.html#ALock.release"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#postgresql.alock.ALock.release" title="Permalink to this definition">¶</a></dt>
<dd><p>Release the locks using the configured identifiers.</p>
</dd></dl>
</dd></dl>
</div>
</div>
</div>
</div>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">Reference</a><ul>
<li><a class="reference internal" href="#module-postgresql"><tt class="docutils literal"><span class="pre">postgresql</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.api"><tt class="docutils literal"><span class="pre">postgresql.api</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.sys"><tt class="docutils literal"><span class="pre">postgresql.sys</span></tt></a><ul>
<li><a class="reference internal" href="#data">Data</a></li>
<li><a class="reference internal" href="#overridable-functions">Overridable Functions</a></li>
</ul>
</li>
<li><a class="reference internal" href="#module-postgresql.string"><tt class="docutils literal"><span class="pre">postgresql.string</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.exceptions"><tt class="docutils literal"><span class="pre">postgresql.exceptions</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.temporal"><tt class="docutils literal"><span class="pre">postgresql.temporal</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.installation"><tt class="docutils literal"><span class="pre">postgresql.installation</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.cluster"><tt class="docutils literal"><span class="pre">postgresql.cluster</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.copyman"><tt class="docutils literal"><span class="pre">postgresql.copyman</span></tt></a></li>
<li><a class="reference internal" href="#module-postgresql.alock"><tt class="docutils literal"><span class="pre">postgresql.alock</span></tt></a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="bin.html"
title="previous chapter">Commands</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="changes-v1.1.html"
title="next chapter">Changes in v1.1</a></p>
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="_sources/reference.txt"
rel="nofollow">Show Source</a></li>
</ul>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="search.html" method="get">
<input type="text" name="q" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="changes-v1.1.html" title="Changes in v1.1"
>next</a> |</li>
<li class="right" >
<a href="bin.html" title="Commands"
>previous</a> |</li>
<li><a href="index.html">py-postgresql 1.1.0 documentation</a> »</li>
</ul>
</div>
<div class="footer">
© Copyright Python+Postgres.
Last updated on Mar 31, 2014.
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.2.2.
</div>
</body>
</html>
|