Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Comments in MySQL Workbench diagram

I have a schema designed in MySQL Workbench. I put descriptions in for the tables, and comments for columns and views.

I created a diagram, and I'd like to see the comments and descriptions in the diagram. Is there any way to do this? I noticed the tooltip shows the comment for the views, but not for tables or columns.

like image 487
SharkAlley Avatar asked May 28 '12 03:05

SharkAlley


People also ask

How do I comment lines in MySQL Workbench?

MySQL Server supports three comment styles: From a # character to the end of the line. From a -- sequence to the end of the line. In MySQL, the -- (double-dash) comment style requires the second dash to be followed by at least one whitespace or control character (such as a space, tab, newline, and so on).

How do I comment multiple lines in MySQL Workbench?

Multi-line comments start with /* and end with */ . Any text between /* and */ will be ignored.

How do I comment out text in MySQL?

In MySQL, a comment that starts with /* symbol and ends with */ and can be anywhere in your SQL statement. This method of commenting can span several lines within your SQL.

What is /* in MySQL?

Standard SQL uses the C syntax /* this is a comment */ for comments, and MySQL Server supports this syntax as well. MySQL also support extensions to this syntax that enable MySQL-specific SQL to be embedded in the comment, as described in Section 9.7, “Comments”. The statement produces no change in value at all.


1 Answers

There's no way to show the comments of tables in the diagram. For documentation purposes you could add text notes to the diagram, however. Unfortunately, they won't be updated automatically, so you will have to copy the comments manually.

In addition you can create a feature request so that such comments can optionally be displayed there.

like image 62
Mike Lischke Avatar answered Sep 23 '22 15:09

Mike Lischke