I would like to know how to update column **numberOfComments** to display number of comments that are made on the post. Can I create a trigger on table **comments** and update column **numberOfComments** in table **posts**?
Tables look something like this.

```
create table posts (
   post_id int primary key,
   post_subject varchar(255),
   numberOfComments int);

create table comments(
   comment_id int primary key,
   comment_text,
   post_id int,
   foreign key (post_id) references posts(post_id));

```