Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Recommended Posts

Posted

I would like to constrain records to only show 1 occurrence of an individual within a found set of records. (see pics for example).I perform a find by date range on table which produces result A. Now I want to constrain that set to get result B.

ie.. If John Smith shows up twice within that date range I want to constrain to only a single record for John Smith.

The idea is produce a report of Unduplicated Individuals Served within a date range.

Screen Shot 2024-08-30 at 7.44.58 AM.png

Screen Shot 2024-08-30 at 7.45.21 AM.png

Posted
15 minutes ago, comment said:

This is a cross-post:
https://community.claris.com/en/s/question/0D5Vy00000G1VPOKA3/constrain-found-set-to-unique-values
and the first answer you received there is a very good one.

I would add that names of individuals are not necessarily unique. You could even have two different people with the same name born on the same day and sharing the same gender. 

 

I will clarify. Each individual within the table does have their own foreign UUID stored on the table next to the primary UUID for the record. So I would not be basing my constrain on "name" but on the foreign UUID. My example was to demonstrate what I am trying to accomplish in the simplest terms possible.

Posted
10 minutes ago, Toddbob said:

Each individual within the table does have their own foreign UUID

But is there a parent table of individuals where this UUID is the primary key? There certainly should be, and all the details describing an individual  - name, DOB, gender - should be listed in this table and only in this table. 

If you do have such table then the solution is trivial (as you have been already told in the other thread). Without it, it becomes cumbersome.

 

 

  • Like 1
Posted (edited)
On 8/30/2024 at 4:49 PM, Toddbob said:

So I would not be basing my constrain on "name" but on the foreign UUID.

So it seems like being in a portal, somehow - what measures of data are we talking about here? Is it millions of records or could a filtered portals be the thing to apply here? Because Ugo's method comes to mind here... which now exists in a filtered portal version:

Quote

Let(
   [
      indexValues = List( Child::ChildID );
      searchValues = List( Child::Category );
      index =
      ValueCount(
         Left(
            indexValues;
            Position( ¶ & indexValues & ¶; ¶ & Child::ChildID & ¶; 1; 1 )
         )
      );
      prevValues = LeftValues( searchValues; index - 1 )
   ];
   IsEmpty( FilterValues( Child::Category; prevValues ) )
)

 

--sd

Edited by Søren Dyhr
Posted

This is an absolute beginner mistake and I should have seen this relationship from go.
My search table is Attendance. I needed to use the People table which should only have a record for a single individual (Primary Key) as my starting table to filter search results on the Attendance table.I was applying the incorrect logic to the issue. Started with a result and trying to work backwards to filter.
A member in Claris Community pointed me in the right direction, I was clearly down a rabbit hole of my own making.
Thank you for your replies.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.