<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Join versus Relate in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451318#M41693</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might try a &lt;A href="http://resources.arcgis.com/en/help/main/10.2/index.html#//00170000006r000000"&gt;Query Table&lt;/A&gt;.&amp;nbsp; I have been recently using them in lieu of one-to-many joins.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You add both tables, and then you input a SQL expression that contains the relationship.&amp;nbsp; It will then "duplicate" records in the spatial table to match the entries in the non-spatial table, and visa versa.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A relate would be significantly different than your current set up.&amp;nbsp; You would select the record in your spatial table, and the matching records would be selected in the non-spatial table, but they would still appear as two separate tables, unlike a join.&amp;nbsp; This may impact your workflows.&amp;nbsp; A query table, however, would function much like the original table, (although it would not support editing).&amp;nbsp; The query table would even show the features if you include the SHAPE@ field!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 07 Feb 2016 05:53:32 GMT</pubDate>
    <dc:creator>MichaelKowalczyk</dc:creator>
    <dc:date>2016-02-07T05:53:32Z</dc:date>
    <item>
      <title>Join versus Relate</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451317#M41692</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good evening.&amp;nbsp; I am trying to decide between using a join versus a relate in ArcMap.&amp;nbsp; I understand that a join supports a one-to-one relationship, but it also says it supports a many-to-one relationship, which may be what I need.&amp;nbsp; Keep reading to help me decide.&amp;nbsp; I also understand that a relate supports/implies a one-to-many relationship.&amp;nbsp; That's the theory.&amp;nbsp; Can you help me apply it?&amp;nbsp; Here's my situation...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a shapefile that I imported into a SQL Server database as a feature class that contains spatial data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have another table in the same SQL Server database, which is not a geodatabase, that contains non-spatial data for the locations in the feature class.&amp;nbsp; This table of non-spatial data has many rows for the same location.&amp;nbsp; Additionally, it will be updated frequently/outside of my knowledge by some automated process.&amp;nbsp; Currently, I am joining the non-spatial data to the spatial data in ArcMap.&amp;nbsp; I realize that I will only get the first match between the two tables, but my front-end, which uses the ArcGIS JS API, sends a rather restrictive query to the map service created from the document in ArcMap, which should only yield one row for each location.&amp;nbsp; This implementation is working fine for me, but I am just wondering about best practices.&amp;nbsp; Should i really be using a relate or should I just reverse the order of the join -- join the spatial data to the non-spatial data?&amp;nbsp; And, in so doing, will I see any improvements in the performance of my map service?&amp;nbsp; It is not horrible, but I am just wondering, generally/best practices-wise speaking.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any thoughts/suggestions/help would be appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks...Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 07 Feb 2016 04:41:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451317#M41692</guid>
      <dc:creator>ChristopherJohnson1</dc:creator>
      <dc:date>2016-02-07T04:41:33Z</dc:date>
    </item>
    <item>
      <title>Re: Join versus Relate</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451318#M41693</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might try a &lt;A href="http://resources.arcgis.com/en/help/main/10.2/index.html#//00170000006r000000"&gt;Query Table&lt;/A&gt;.&amp;nbsp; I have been recently using them in lieu of one-to-many joins.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You add both tables, and then you input a SQL expression that contains the relationship.&amp;nbsp; It will then "duplicate" records in the spatial table to match the entries in the non-spatial table, and visa versa.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A relate would be significantly different than your current set up.&amp;nbsp; You would select the record in your spatial table, and the matching records would be selected in the non-spatial table, but they would still appear as two separate tables, unlike a join.&amp;nbsp; This may impact your workflows.&amp;nbsp; A query table, however, would function much like the original table, (although it would not support editing).&amp;nbsp; The query table would even show the features if you include the SHAPE@ field!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 07 Feb 2016 05:53:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451318#M41693</guid>
      <dc:creator>MichaelKowalczyk</dc:creator>
      <dc:date>2016-02-07T05:53:32Z</dc:date>
    </item>
    <item>
      <title>Re: Join versus Relate</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451319#M41694</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the reply, Michael.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, I am wondering how different my workflow, in my front-end code, would be...testing it out now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks...Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 07 Feb 2016 05:56:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451319#M41694</guid>
      <dc:creator>ChristopherJohnson1</dc:creator>
      <dc:date>2016-02-07T05:56:32Z</dc:date>
    </item>
    <item>
      <title>Re: Join versus Relate</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451320#M41695</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;More thoughts on your suggestion, Michael.&amp;nbsp; Using the query table, since the data in my non-spatial table could change at anytime, that would mean that I would have to automate the building of the query table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks...Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Feb 2016 02:26:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/join-versus-relate/m-p/451320#M41695</guid>
      <dc:creator>ChristopherJohnson1</dc:creator>
      <dc:date>2016-02-16T02:26:45Z</dc:date>
    </item>
  </channel>
</rss>

