src/tutorial/funcs.source: Wrong comment?

From: "Daniel Westermann (DWE)" <daniel(dot)westermann(at)dbi-services(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: src/tutorial/funcs.source: Wrong comment?
Date: 2021-01-13 10:39:37
Message-ID: GVAP278MB04242DCBF5E31F528D53FA18D2A90@GVAP278MB0424.CHEP278.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

in "src/tutorial/funcs.source" there is this block:

-----------------------------
-- Creating SQL Functions with multiple SQL statements
-- you can also create functions that do more than just a SELECT.
--
-- 14MAR99 Clark Evans: Does not quite work, commented out for now.
--
-----------------------------

-- you may have noticed that Andy has a negative salary. We'll create a
-- function that removes employees with negative salaries.
--
-- SELECT * FROM EMP;
--
-- CREATE FUNCTION clean_EMP () RETURNS integer
-- AS 'DELETE FROM EMP WHERE EMP.salary <= 0;
-- SELECT 1 AS ignore_this'
-- LANGUAGE SQL;
--
-- SELECT clean_EMP();
--
-- SELECT * FROM EMP;

Actually it does work and I do not see a reason why this still should be commented. Thoughts?

Regards
Daniel

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dorian Hoxha 2021-01-13 10:54:07 Alter timestamp without timezone to with timezone rewrites rows
Previous Message Heikki Linnakangas 2021-01-13 10:34:08 Re: Yet another fast GiST build