diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2024-01-03 12:22:00 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2024-01-03 12:22:00 -0500 |
commit | 54790f4b3f048db8f18e17966ad3bfb428e5b312 (patch) | |
tree | 70d6c52740428dfa2bc495807120389e59c84941 | |
parent | 69d7edb06fc69da114b075be58dd4318916500e5 (diff) | |
download | postgresql-54790f4b3f048db8f18e17966ad3bfb428e5b312.tar.gz postgresql-54790f4b3f048db8f18e17966ad3bfb428e5b312.zip |
Doc: Python's control flow construct is try/except not try/catch.
Very ancient thinko, dating evidently to 22690719e.
Spotted by gweatherby.
Discussion: https://postgr.es/m/170423637139.1288848.11840082988774620003@wrigleys.postgresql.org
-rw-r--r-- | doc/src/sgml/plpython.sgml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/src/sgml/plpython.sgml b/doc/src/sgml/plpython.sgml index c62361b6f80..d7fbb4da0c4 100644 --- a/doc/src/sgml/plpython.sgml +++ b/doc/src/sgml/plpython.sgml @@ -1323,7 +1323,7 @@ plan = plpy.prepare("INSERT INTO operations (result) VALUES ($1)", ["text"]) plpy.execute(plan, [result]) $$ LANGUAGE plpythonu; </programlisting> - Note that the use of <literal>try/catch</literal> is still + Note that the use of <literal>try</literal>/<literal>except</literal> is still required. Otherwise the exception would propagate to the top of the Python stack and would cause the whole function to abort with a <productname>PostgreSQL</productname> error, so that the |