<?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: arcpy.AddJoin Not Working In ArcGIS Pro Script in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1215792#M60207</link>
    <description>&lt;P&gt;I am having the same problem. Script works in the ArcGIS Pro python command window but will not run as a standalone script in a toolbox. Data and table both in a local FGDB. Would be nice to find a way around this. Creating in-memory layers has not worked so far.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 23 Sep 2022 23:53:39 GMT</pubDate>
    <dc:creator>AndyWells</dc:creator>
    <dc:date>2022-09-23T23:53:39Z</dc:date>
    <item>
      <title>arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503309#M22106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to join a layer in an ArcGIS Pro map to a table using a scripting tool. The layer is called 'Heights', and is being joined to a table called 'Names'. The Python code below is working&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;when run from the Python window within ArcGIS Pro. However, when I try to run it as a script from the Catalog Pane then the join does not happen, even though the geoprocessing detail does not throw up any error messages. Am I missing a step or does this just not work in ArcGIS Pro?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcpy
&lt;SPAN class="comment token"&gt;#Reference map document from within ArcGIS Pro&lt;/SPAN&gt;
aprx &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;mp&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;ArcGISProject&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'CURRENT'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
map &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; aprx&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;activeMap
&lt;SPAN class="comment token"&gt;# Local variables:&lt;/SPAN&gt;
Heights &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"Heights"&lt;/SPAN&gt;
toTable &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; r&lt;SPAN class="string token"&gt;"C:\#workspace\Names"&lt;/SPAN&gt;
&lt;SPAN class="comment token"&gt;# Process: Add Join&lt;/SPAN&gt;
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;AddJoin_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Heights&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; toTable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'AI_LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'KEEP_ALL'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 22:04:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503309#M22106</guid>
      <dc:creator>KennethGibson</dc:creator>
      <dc:date>2021-12-11T22:04:50Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503310#M22107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you are running as a separate script the concept of "Current" isn't known, it is only valid in Pro's python window.&lt;/P&gt;&lt;P&gt;Have you tried replacing Current with the path to the aprx and setting arcpy's env to it so that layers can be referenced without full paths (eg Heights)&lt;/P&gt;&lt;P&gt;Also &amp;nbsp;&amp;nbsp;&lt;A href="https://community.esri.com/blogs/dan_patterson/2016/08/14/script-formatting"&gt;/blogs/dan_patterson/2016/08/14/script-formatting&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;would help people reference line numbers, if the above is indeed a script&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 10:11:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503310#M22107</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2019-10-28T10:11:12Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503311#M22108</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Dan&lt;/P&gt;&lt;P&gt;Thanks for the advice about the code rendering. I have now fixed this is the post.&lt;/P&gt;&lt;P&gt;I am bit confused by the 'Current' not being known as I am able to switch&amp;nbsp;the Heights&amp;nbsp;layer off in the map simply by adding the following lines to the script:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;lyrs &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; map&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;listLayers&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;World5m_Heights&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
lyrs&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;visible &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="token boolean"&gt;False&lt;/SPAN&gt;‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;The full script then becomes:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcpy
&lt;SPAN class="comment token"&gt;#Reference map document from within ArcGIS Pro&lt;/SPAN&gt;
aprx &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;mp&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;ArcGISProject&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'Current'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
map &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; aprx&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;activeMap
&lt;SPAN class="comment token"&gt;# Local variables:&lt;/SPAN&gt;
Heights &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"Heights"&lt;/SPAN&gt;
toTable &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; r&lt;SPAN class="string token"&gt;"C:\#workspace\Names"&lt;/SPAN&gt;
&lt;SPAN class="comment token"&gt;# Toggle Heights layer off&lt;/SPAN&gt;
lyrs &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; map&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;listLayers&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Heights&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
lyrs&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;visible &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="token boolean"&gt;False&lt;/SPAN&gt;
&lt;SPAN class="comment token"&gt;# Process: Add Join&lt;/SPAN&gt;
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;AddJoin_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Heights&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; toTable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'AI_LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'KEEP_ALL'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This would indicate that the layer is being referenced and manipulated OK using the script. However, the join does not work. If I change the parameters in the join to...&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;AddJoin_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;lyrs&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; toTable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'AI_LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'KEEP_ALL'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;...it still doesn't work.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 22:04:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503311#M22108</guid>
      <dc:creator>KennethGibson</dc:creator>
      <dc:date>2021-12-11T22:04:53Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503312#M22109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Kenneth, Are you running it in the python window within Pro? or from a separate python IDE?&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://pro.arcgis.com/en/pro-app/tool-reference/data-management/add-join.htm" title="https://pro.arcgis.com/en/pro-app/tool-reference/data-management/add-join.htm"&gt;Add Join—Data Management toolbox | ArcGIS Desktop&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;on a lark, pass the full path to both to test whether something is wrong with one of the two tables&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;SPAN style="display: inline !important; float: none; background-color: #ffffff; color: #4c4c4c; font-family: 'Avenir Next W01','Avenir Next W00','Avenir Next','Avenir','Helvetica Neue',sans-serif; font-size: 15.8px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px;"&gt;If the input is a feature class or dataset path, this tool will automatically create and return a new layer with the result of the tool applied.&lt;/SPAN&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 12:41:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503312#M22109</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2019-10-28T12:41:53Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503313#M22110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm running the script from a toolbox within the Catalog Pane of an ArcGIS Pro project. This has to run within the project and on layers in the&amp;nbsp;map because the full script will actually loop through all the layers in the map in order to join each onel to the Names table so that the map labels can reference one of the columns in the joined table. This is a script that runs perfectly well in ArcMap using the same method (i.e. a toolbox script in ArcCatalog from within ArcMap) and all I am trying to do is update the script so that it works within ArcGIS Pro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I do as you suggest to the actual feature classes rather than the map layers then the join will likely work OK but there will be no way to actually view if it is successful or not because the join will be in a temporary state in order to allow processes like Calculate Fields to run. Instead, I need this to work on the layers within the ArcGIS Pro map. As mentioned it seems that I can manipulate the layers OK (tested using the lyr.visible = False code) but I can't get the join to work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since the code works within the Python window in ArcGIS Pro then I'm confident there is nothing wrong with the actual tables.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 14:01:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503313#M22110</guid>
      <dc:creator>KennethGibson</dc:creator>
      <dc:date>2019-10-28T14:01:52Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503314#M22111</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The last thing I can think of is that if the table is open when the join is being performed, it doesn't show, but needs to be closed and reopened.&amp;nbsp; I am also a bit confused about the reference to the totable which appears to be on disk and not a reference to a table view.&lt;/P&gt;&lt;P&gt;Maybe someone else can see what I am overlooking&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 14:23:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503314#M22111</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2019-10-28T14:23:19Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503315#M22112</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, I had thought to reload the table but to no avail I'm afraid. I've also tried to&amp;nbsp;create a view of the Names table and then joining to that. The following code is added with some fieldinfo:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;MakeTableView_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;toTable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'Table_View'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;''&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;''&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; fieldinfo&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;That then alters the AddJoin command to:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;AddJoin_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Heights&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'Table_View'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'AI_LINK_ID'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'KEEP_ALL'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;It sounds like we may not be able to figure this out.&amp;nbsp;If anyone is able to confirm that this indeed does not work in ArcGIS Pro then I will raise it as a bug or future enhancement. Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 16:29:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503315#M22112</guid>
      <dc:creator>KennethGibson</dc:creator>
      <dc:date>2019-10-28T16:29:26Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503316#M22113</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A class="link-titled" href="https://support.esri.com/en/Search-Results#search?q=addjoin&amp;amp;content-type=Bugs" title="https://support.esri.com/en/Search-Results#search?q=addjoin&amp;amp;content-type=Bugs"&gt;Esri Support Search-Results&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;nothing obvious... except the warning that the inputs must be layers or table views&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Oct 2019 17:43:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/503316#M22113</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2019-10-28T17:43:45Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1175125#M55281</link>
      <description>&lt;P&gt;I'm having the same issue.&amp;nbsp; I'm trying to join a table (that exists inside a FGDB) to a feature class (also in the same FGDB) from IDLE.&amp;nbsp; The Python join command&amp;nbsp; works in the ArcPro Python window, but does not execute correctly when run as a standalone script from the IDLE.&lt;/P&gt;</description>
      <pubDate>Wed, 18 May 2022 15:52:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1175125#M55281</guid>
      <dc:creator>LouisHill1</dc:creator>
      <dc:date>2022-05-18T15:52:26Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1215792#M60207</link>
      <description>&lt;P&gt;I am having the same problem. Script works in the ArcGIS Pro python command window but will not run as a standalone script in a toolbox. Data and table both in a local FGDB. Would be nice to find a way around this. Creating in-memory layers has not worked so far.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Sep 2022 23:53:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1215792#M60207</guid>
      <dc:creator>AndyWells</dc:creator>
      <dc:date>2022-09-23T23:53:39Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.AddJoin Not Working In ArcGIS Pro Script</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1240743#M63381</link>
      <description>&lt;P&gt;I was struggling with a similar problem and came across this thread.&amp;nbsp; According to &lt;A title="Add Join (Data Management)" href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/add-join.htm" target="_blank" rel="noopener"&gt;the documentation&lt;/A&gt;:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;To see the results of a join created in a script tool, the tool must include the layer as a &lt;A href="https://pro.arcgis.com/en/pro-app/3.0/arcpy/geoprocessing_and_python/setting-script-tool-parameters.htm#GUID-59C4A61C-AC33-4BA3-8453-AC8328E34453" target="_blank" rel="noopener"&gt;derived output parameter&lt;/A&gt;. Similarly, the &lt;SPAN class=""&gt;Updated Input Layer or Table View&lt;/SPAN&gt; parameter must be set as a derived output parameter in a &lt;A href="https://pro.arcgis.com/en/pro-app/3.0/help/analysis/geoprocessing/modelbuilder/modelbuilder-vocabulary.htm" target="_blank" rel="noopener"&gt;model tool&lt;/A&gt; to see the joined results.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;So in your case, you'd have to add a derived output parameter to your script, save the output of the Add Join tool to a variable, and set that parameter as that variable, like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;import arcpy
#Reference map document from within ArcGIS Pro
aprx = arcpy.mp.ArcGISProject('CURRENT')
map = aprx.activeMap
# Local variables:
Heights = "Heights"
toTable = r"C:\#workspace\Names"
# Process: Add Join
heights_joined = arcpy.AddJoin_management(Heights, 'LINK_ID', toTable, 'AI_LINK_ID', 'KEEP_ALL')‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍  # save result to heights_joined
arcpy.SetParameter(0, height_joined)  # "0" is parameter index&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;In my case, I wanted to add a definition query and apply symbology to the joined layer, which I couldn't do in that script, since the joined layer isn't available until the script ends (since it's an output).&amp;nbsp; So I just had to add those steps to a second script, and then I used model builder to run the first script and use the derived output as an input for the second script, which set the definition query and applied the symbology.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 19:44:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcpy-addjoin-not-working-in-arcgis-pro-script/m-p/1240743#M63381</guid>
      <dc:creator>jdyerLACSD</dc:creator>
      <dc:date>2022-12-13T19:44:24Z</dc:date>
    </item>
  </channel>
</rss>

