Comments history tracker

Hi,
Can anyone help how to track the comments
Ex: I had tickets table and Issue comments is one of the columns.
This Issue comments always should be empty to enter to text. Now I want to track the text entered in Issue comments into another column(may be virtual column) with a concatenate time.
I am using spreadsheet as datasource.
Thanks in advance

Did you have a chance to look at this thread: Wants to save multiple comments

Aleksi linked some solutions and a sample app that might be helpful. If this doesn’t answer your question, let us know more details on what you’re trying to achieve. Best of luck!

1 Like

Yes @kamila, I looked into it. Aleski created a new child table. But in my case creating a new table might be constraint.
Can’t we do with expression?
More details:

  1. Column name: Issue comments - Always it should be blank.(Ex Text: please include a new phone number field)
  2. Column name: Comments History - It should records the text entered in Issue comment(#1) column + useremail of who entered.
    (Ex: please include a new phone number field, username, timenow()

Make an action:
Data: Set the values of some columns in this row.


Comments History: CONCATENATE(USEREMAIL()," - “,Now(),”
“,[Issue Comments],”
",[Comments History])

This will put the new comment on the top of the other previous comments, so you can scroll down to get previous comments, and the most recent are at the top, so you don’t have to scroll down. It will also put a line of space between the comments. It will also add the user email and time to the top of each post, automatically

Issue Comments: “”

This will get rid of the issue comments, once they have been added to the history

Let me know if this formula doesn’t work or you need help adding something to it.

1 Like

Also, make sure you go to the Table Name_Form, scroll down to Behavior, and add in this action to trigger when the form is saved, or else the action will never trigger.

You may also want to hide the comments history box when in form view with a context() formula for the ShowIf section, and hide the issue comments column in detail view with a context() formula.

1 Like

What you want is certainly possible.

The Issue comments column should be of type LongText to allow multi-line comments. Also set its Initial value expression to "", which will clear its value. Then set Reset on edit to ON. Setting this to ON will cause the Initial value to be applied to the column each time the row is modified, such as when edited in a form. This gets you the blank Issue comments field each time.

Then, use a regular (non-virtual) column to keep the running collection of comments (named Comment History, e.g.), of type LongText, with an App formula expression something like:

CONCATENATE(
[Comment History],
"
~~~~~
",
NOW(),
"
",
[Issue Comments]
)

Note carefully the double-quotes (") are on separate lines.

Thanks @retailpartnercom.
It works Perfectly.

1 Like

Thanks @Steve.
It is working fine, but as it is “App formula” , it is executing everytime.
I mean like,
I entered text on comments field and i clicked on empty area(somewhere) in App and if I again a new comment - History comments coming two times.

1 Like

Ah, yeah. Whoops! This should work right:

(
  [Comment History]
  & IFS(
    ISNOTBLANK([Issue Comments]),
      CONCATENATE(
"
~~~~~
",
        NOW(),
"
",
        [Issue Comments]
      )
  )
)
2 Likes

Thanks @Steve

1 Like