Changeset: f2fd8588db82 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f2fd8588db82
Modified Files:
        clients/mapiclient/mhelp.c
        sql/ChangeLog.Mar2018
Branch: Mar2018
Log Message:

Extend sql/Changelog.Mar2018 to include new SQL COMMENT ON functionality as 
added
with https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ecbeb4a7285d


diffs (57 lines):

diff --git a/clients/mapiclient/mhelp.c b/clients/mapiclient/mhelp.c
--- a/clients/mapiclient/mhelp.c
+++ b/clients/mapiclient/mhelp.c
@@ -93,6 +93,13 @@ SQLhelp sqlhelp[] = {
         "CASE scalar_expression [ when_statement ...]  [ELSE 
procedure_statement ... ] END CASE",
         NULL,
         "See also 
https://www.monetdb.org/Documentation/SQLreference/Flowofcontrol"},
+       {"COMMENT",
+        "Add, update or remove a comment or description for a database object",
+        "COMMENT ON [ SCHEMA | TABLE | VIEW | COLUMN | INDEX | SEQUENCE |\n"
+        "           FUNCTION | PROCEDURE | AGGREGATE | FILTER FUNCTION | 
LOADER ]\n"
+        "     qname IS [ 'my description text' | NULL | '' ]",
+        NULL,
+        NULL},
        {"COMMIT",
         "Commit the current transaction",
         "COMMIT [ WORK ] [ AND CHAIN | AND NO CHAIN ]",
@@ -334,7 +341,7 @@ SQLhelp sqlhelp[] = {
         NULL},
        {"IF",
         "",
-        "IF  search_condition THEN procedure_statement ...\n"
+        "IF search_condition THEN procedure_statement ...\n"
         "[ELSE IF search_condition THEN procedure_statement ... ]...\n"
         "[ ELSE procedure_statement ... ] END IF",
         "search_condition,procedure_statement",
diff --git a/sql/ChangeLog.Mar2018 b/sql/ChangeLog.Mar2018
--- a/sql/ChangeLog.Mar2018
+++ b/sql/ChangeLog.Mar2018
@@ -15,6 +15,27 @@
 - Added new system view: sys.var_values which shows the values for
   system variables.
 
+* Fri Jan 12 2018 Joeri van Ruth <joeri.van.r...@monetdbsolutions.com>
+- Added support for COMMENT ON statements using SQL syntax:
+   COMMENT ON [ SCHEMA | TABLE | VIEW | COLUMN | INDEX | SEQUENCE |
+              FUNCTION | PROCEDURE | AGGREGATE | FILTER FUNCTION | LOADER ]
+        qname IS [ 'my description text' | NULL | '' ] ;
+  For COLUMN the qname can be "table_name"."column_name" or fully qualified
+  as in: "schema_name"."table_name"."column_name".
+  For FUNCTION, PROCEDURE, AGGREGATE, FILTER FUNCTION and LOADER the qname
+  may need to include the signature (argument types) to be able to
+  differentiate between multiple overloaded functions which have the same name
+  and schema.
+  By specifying IS NULL or IS '' you remove the comment for the database 
object.
+  If a database object is dropped, the associated comment is also removed.
+  Note: it is not allowed or possible to add comments for temporary tables or
+        objects in schema "tmp".
+  The sql catalog has been extended with system table: sys.comments and system
+  views: sys.describe_all_objects and sys.commented_function_signatures. These
+  system views are used by the dump functionality as provided in msqldump and
+  mclient and not intended to be used by users or user applications.
+  The keyword 'COMMENT' has now become a reserved keyword.
+
 * Thu Dec  7 2017 Martin van Dinther <martin.van.dint...@monetdbsolutions.com>
 - Removed system function sys.environment(). It was a duplicate of system
   function sys.env().
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to