Back to articles list
- 1 minutes read

Tip #7 – How to include comments in SQL script

You can comment on your database objects (tables, columns, views) in Vertabelo. You can also include this metadata in your database, where it can be accessed by your SQL developers or DBAs.

Here’s how you can do it.

Go to your database model:

Click SQL generation settings in the Model properties panel on the right:

Check the Include comments for database objects option:

Let’s try out how it works.

Assume that you want to add your comment to the photo_file column in the photo table.

Select the table. In the Table properties panel on the right, find the appropriate column, and then expand its properties section:

Write your comment in the Comment text field:

Now, you can see that your comment is added to the generated SQL script:

Let’s check your comment in the created PostgreSQL database. You can do this by using the psql command on the command line:

Your comment should also be visible in graphical environments, like pgAdmin III.

 
 
go to top

Our website uses cookies. By using this website, you agree to their use in accordance with the browser settings. You can modify your browser settings on your own. For more information see our Privacy Policy.