1 Reply Latest reply on Jun 17, 2016 2:26 PM by TSPigeon

    Selecting unique value to display in another table?


      I have two tables: Contacts and Properties

      The fields in the Contacts table includes name, company, job title, address, etc. (address being the most important).

      Some of my contacts share the same address, so what I'm trying to do is display a list of unique addresses in the properties table with all of the contacts associated with that address showing too. I tried to do this by setting up a field in the properties table named address as well, and wrote a calculation to try to auto-enter values without duplicates.

      Here's what I've tried:

      ExecuteSQL("SELECT DISTINCT Address FROM Contacts" ; " " ; " ")

      What shows up in the address field in the contacts page is a simple "?"

      What do I do? Pretty new to filemaker so please help.

        • 1. Re: Selecting unique value to display in another table?



          Thank you for your post!


          [ ExecuteSQL ( "SELECT DISTINCT AddressField FROM ContactsTable" ; " " ; "¶" ) ] is what I would use to get a list of Addresses. Have you tried evaluating it with the Data Viewer in FileMaker Pro Advanced to make sure it's not a field option issue?


          Also, I am going to move this thread from the FileMaker Community Feedback Space, which is specifically for input on the Community itself, to the Discussions Space where you should receive more views and potentially more advice!



          FileMaker, Inc.