Jump to content
  • 0

Filtering Data from 2 Related Tables


Newlogiq

Question

Hello...I need some guidance, please.  I have a view of 2 tables.  The first table contains customer information and an order number.  The second table contains the order number plus a variety of notes associated with that order that have been date and time stamped.  There are multiple notes entries for each order number.  I'm trying to create a report that only shows the order number 1 time when a date from the second table matches some filtering criteria.  Specifically, I want to only show those orders (again, just show order number 1 time) that do NOT have a note within XX days of today.  How would you do this?  I'm fairly new to Caspio...thank you.

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

Hello, I have something similar in my application but with a different structure.

From what I understand, you have the order id in the customer table, if your order can only be made by one customer, the order id should be removed from the customers table and in the orders table you should use the customer id. Something like this schema:
image.png.166b2d80e8be452b799f3fb2828cf006.png

 

Regarding the timestamp, there is an option in the element which allows to set some criteria for dates like the one I have in my report:

image.png.dcda22a495a39f11ff020652a6959539.png

And for the Note, you can also set it to check if it is empty in text elements:

image.png.523377f358da50cd27d6ebe9ca1e7189.png

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...