Skip to main content
Question

Suggestions for how to ""snapshot"" the database

  • March 27, 2019
  • 0 replies
  • 155 views

I have an app with several tables which keeps project information throughout the quoting, execution, and closing phases.  I want to get a "snapshot" when a project moves from quoting to execution and then again from execution to closing phases.

I can create an action to take the fields from the main table and put them into a "snapshot" table when this happens.  The problem is that important info like the parts and the material is in other tables.  These are the items that are likely to change and I want to track that.

Am I missing an easy solution?
This topic has been closed for replies.

If you use an Automation rather than an Action you can do up to 50 separate steps in a row based on a trigger, so for example you could possibly capture some data from other tables as well.

It sounds like you're headed in the right direction.
1. Why can't you capture the "parts and material" fields in the "snapshot table".
2. Do you need this information purely for logging purposes, or do you plan on doing some type of calculation with the data, like # of changes in a given time frame etc.?

Also, it looks like there is already native support for "snapshotting" lookup fields. Does this help you? https://help.quickbase.com/user-assistance/setting_up_snapshot_fields.html?Highlight=snapshot

  • Registered
  • March 27, 2019
You may want to consider using one of the current child tables (or creating a separate child table) where you can pull down important fields from all the relationships related to a project. We take our daily snapshot from the lowest child record so that we can pull all related fields from the parents down (it is much easier than trying to pull all fields up the relationship list).

Hi Chris
I ran into the same issue when building a snapshot table for multiple tables (and ironically, when a user switches phases on a project). My approach was as follows:
 1) In the child table: create a formula field that is comma delimited that combines the columns (or the delimiter of your choice) with a newline character at the end
2) In the Relationship screen->Add Summary: Use the new Combined Text summary field to summarize the formula field for all the Child records to the Parent record 
3) In the Parent table: Convert the Data to Text in another formula using ToText()
4) Use an Automation to snapshot the Value in a Text field in the Snapshot table.
Now that you have a record or (metadata) of the related record of the child table, you can reconstruct them through string manipulations in a variety of ways using formula fields or Javascript.
For my use case, I used javascript to reconstruct the data.
Can you tell me more about the use case what you are trying to accomplish?

  • Author
  • Registered
  • March 31, 2019
So what I ended up with (so far) was an Automation.

When a Project [status field] is modified, that record becomes the trigger.

The automation then copies the child table Parts related to the Project into the Snapshot Parts table.
It then copies the Project into the Snapshot Projects table.

It has to occur in this order because I then needed a second automation to create the relationship between the Snapshot Parts child records and the Snapshot Project parent record.

This trigger is the creation of a record in the Snapshot Projects table.  

When the Snapshot Parts were created, the related Snapshot Project field was blank.  I am currently trying to use the trigger of the creation of a Snapshot Project to fill in the relationship between the two.

If this works, it should be relatively easy to also handle any other child tables that I wish and I am not creating any additional fields.

The potential problem could occur in a multiuser environment if two people change project status at the exact same time.  There would be a relationship error.  That is rare enough that I think that I will take the risk.



I think if you snapshot the Project table first, it will be better.
In the snapshot, copy the Original Project record id. Then trigger a Copy Record action when a Record is Added in the Project Snapshot by looking up each Record in the Part table based on the Project Record ID.


  • Author
  • Registered
  • April 1, 2019
I cannot access the Project>Record ID in the Filter.  I can only access the Trigger which is Project Snapshot>Record ID or Parts>Record ID

  • Author
  • Registered
  • April 2, 2019
And then, as usually happens with Quickbase, it stops working altogether.  

I removed an extraneous field from the table, and then removed it from the automation and now the Automation fails to trigger (even though that field was never used). 

Even though the trigger is on any add, change, or delete in the entire table, it now fails to trigger at all.  <sigh>    One step forward, two steps back.