Timestamp for each Record

Hi guys, there is a type of column I call it Timestamp for store date Time value on each SAVE, is there are way when the record form open, it compare the Timestamp between database value and current form value that for define someone has updated that record to prevent SAVE or being overwrites without perform full sync of data all the time. Or there is already with this specific function I got over look.

Solved Solved
0 3 304
1 ACCEPTED SOLUTION

Hi @Tommy62


@Tommy62 wrote:

Der Timestamp wird immer bei Öffnung eines Formulars auf "now()" gesetzt sein. Es wäre auch möglich, den Timestamp auf die Zeit zu setzen, wenn das Formular gespeichert wurde.

Um den Zeitpunkt bei einer Editierung des Formulars festzuhalten, benötigen Sie eine neue Spalte [EditDateTime]. 


"The timestamp will always be set to "now()" when a form is opened. It would also be possible to set the timestamp to the time when the form was saved.

To record the time when editing the form, you need a new column [EditDateTime]."

Can you please answer in English, it's easier for everyone to read the thread, and understand it or answer it 🙂

@jackleung876 

1) Is your question relating to any concurrent update? If so, you may benefit from using the Quick Sync feature as described here: Offline and Sync: The Essentials - AppSheet Help

Make sure the security filter is simple enough, as described in the documentation.

Aurelien_0-1690261712249.png

2) If you are willing to avoid a "too-close" in time update, the suggestion by @Tommy62 makes sense.

You would have two timestamp columns: the one being updated with NOW(), and the other one that would be updated using a "on form saved event action". 

In such case, you would need to compare the timestamp1 with timestamp2, for example with this expression for a 10 minutes waiting time:

[timestamp2]-[timestamp1]<"000:10:00"

Here is an excellent Tips & Trick post from @Joseph_Seddik

The notions of TIME and DURATION and how to use in... - Google Cloud Community

The "on form saved event action" would be a data action that would update the [TimeStamp2] with [TimeStamp1] action, and would be triggered here:

Aurelien_1-1690262192209.png

For reference: 

View events - AppSheet Help

 

View solution in original post

3 REPLIES 3

Der Timestamp wird immer bei Öffnung eines Formulars auf "now()" gesetzt sein. Es wäre auch möglich, den Timestamp auf die Zeit zu setzen, wenn das Formular gespeichert wurde.

Um den Zeitpunkt bei einer Editierung des Formulars festzuhalten, benötigen Sie eine neue Spalte [EditDateTime]. 

Thank You sir, but that information is already known on the App-Sheet "Help Center" Page. My issue is how can reflect the "Timestamp" prevent user to perform SAVE when that "Timestamp" has been updated by someone.

Hi @Tommy62


@Tommy62 wrote:

Der Timestamp wird immer bei Öffnung eines Formulars auf "now()" gesetzt sein. Es wäre auch möglich, den Timestamp auf die Zeit zu setzen, wenn das Formular gespeichert wurde.

Um den Zeitpunkt bei einer Editierung des Formulars festzuhalten, benötigen Sie eine neue Spalte [EditDateTime]. 


"The timestamp will always be set to "now()" when a form is opened. It would also be possible to set the timestamp to the time when the form was saved.

To record the time when editing the form, you need a new column [EditDateTime]."

Can you please answer in English, it's easier for everyone to read the thread, and understand it or answer it 🙂

@jackleung876 

1) Is your question relating to any concurrent update? If so, you may benefit from using the Quick Sync feature as described here: Offline and Sync: The Essentials - AppSheet Help

Make sure the security filter is simple enough, as described in the documentation.

Aurelien_0-1690261712249.png

2) If you are willing to avoid a "too-close" in time update, the suggestion by @Tommy62 makes sense.

You would have two timestamp columns: the one being updated with NOW(), and the other one that would be updated using a "on form saved event action". 

In such case, you would need to compare the timestamp1 with timestamp2, for example with this expression for a 10 minutes waiting time:

[timestamp2]-[timestamp1]<"000:10:00"

Here is an excellent Tips & Trick post from @Joseph_Seddik

The notions of TIME and DURATION and how to use in... - Google Cloud Community

The "on form saved event action" would be a data action that would update the [TimeStamp2] with [TimeStamp1] action, and would be triggered here:

Aurelien_1-1690262192209.png

For reference: 

View events - AppSheet Help

 

Top Labels in this Space