How can I look up the previous days data & show it on the same form as what the user will enter (current day)?

  • 0
  • 1
  • Question
  • Updated 4 years ago
  • Answered

How can I look up the previous days data & show it on the same form as what the user will enter (current day)?  I have test cases that teams provide daily via a form.  The Parent table is Planned Test Cases and the Child Table is Daily Test Cases.  Here is my end goal:  on the child form, i'd like to show the "previous days test results" next to current day (which will be blank until the user enters the info).  The previous days test information is to remind them of what happened the day before.  

Now, how best to do that?  Do i do a reverse look up to the parent based on date (MAX[Today]) to pull the fields like Passed, Failed, Blocked, etc to the parent?  Then do i map them back to the child???  if so, how do i do that?  I tried to set up a reverse look up but did something terribly wrong i suppose.

I've heard of "snapshotting" but i cant get that to work either.  HELP...this part is due Wednesday!!!  :-(  I'd attach a pic but it doesnt appear that i can.

Photo of Jana

Jana

  • 324 Points 250 badge 2x thumb

Posted 4 years ago

  • 0
  • 1
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 62,448 Points 50k badge 2x thumb
You could start down the track you were on to get the Maximum Record ID Summarized up to the Planned Test Cases, and then do a Reverse Relationship where One Daily Test is related to Many Planned Test Cases based on that summary maximum field as the reference field in the right side of the Relationship and then pulling down the lookup fields down the Parent. Then do normal lookups down to the child Daily Test Cases record.

But there is a stupid simpler solution so let's try that first.

On the Daily Test Cases table make a new field of type Report Link call Daily Test Case History. Configure the left side as Related Planned Test Case. Then navigate to Configure the right side to the same field! Related Planned Test Case.

Put the Report link on your form and set the form propeties to show the Daily Test Records right on the form as an embedded report. Instead of the default report picket fields, create an unfiltered report with the fields and sort how you you like of Daily Test Results and adjust the form Properties to use that report.


Voila! Create one field and one report and each child has the list of all test results, even in Add Mode.
Photo of Jana

Jana

  • 324 Points 250 badge 2x thumb
Not quite your usual type of response Mark, but quite comical i suppose??? :smile:

What i am going for isnt just a simple embedded table, but more like what you started to say, however, every time i try to make one table Record ID relate on the other, the option to look it up isnt there.  Not going for the table look...going for something a little better looking and more advanced...even though it seems i cant quite grasp something what seems to be simple. :-/  Below is what i ideally would like it to look like on the Child form.  On the parent record, I got the relationship to pull the date and data, however, you had to pick the date vs. it just being the MAX date.  Not sure what i'm doing wrong.
          Previous     Current
Pass     50
Fail        10
Block     10
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 62,448 Points 50k badge 2x thumb
So you don't want an embedded report and you do want to pull the data form the most recent child back up to the parent so it can go back down to the child.

I did try to describe the steps in my response and I am assuming the the Key field to the Child table is the [Record ID#] field.

1. Summary maximum field on the Main Relationship of the Maximum Record ID#. Call it Record ID# of the most recent Daily Test Case.

2.New Relationship where 1 daily test case is related to many Planned test Cases and remember to use that new field as your reference field on the right side.


3. Lookup the data values you want form the daily test cases to the planned test cases.

4. Lookup those same values back down from the Parent down to the child in the main relationship.
Photo of Jana

Jana

  • 324 Points 250 badge 2x thumb
Thanks Mark!  I had to completely rebuild my app to get the relationships to work.  I must have messed it up beyond repair originally.  Thank you again for getting back with me! I have another "how to" question I need to post.  Maybe you'll be the brain behind that one too. :smile: