<?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: Unable to generate an attachment match table with pictures stored in individual subfolders using python. in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/unable-to-generate-an-attachment-match-table-with/m-p/195113#M14964</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Michael,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="string token"&gt;"*.jpg"&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;Instead of just:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="string token"&gt;".jpg"&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;&lt;/P&gt;&lt;P&gt;Here is the updated line:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;GenerateAttachmentMatchTable_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Fleetdata&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; folder&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; Matchtable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"RadioCall"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"*.jpg"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"RELATIVE"&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;&lt;/P&gt;&lt;P&gt;Also, this thread discusses this tool:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/thread/84001"&gt;Generate Attachment Match Table - Python script issue&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~Alex&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 11 Jul 2017 21:03:19 GMT</pubDate>
    <dc:creator>AlexanderBrown5</dc:creator>
    <dc:date>2017-07-11T21:03:19Z</dc:date>
    <item>
      <title>Unable to generate an attachment match table with pictures stored in individual subfolders using python.</title>
      <link>https://community.esri.com/t5/python-questions/unable-to-generate-an-attachment-match-table-with/m-p/195112#M14963</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First off, I'm not very good at python but I need help&amp;nbsp;with the follow code. All I'm trying to do is generate an attachment match table by selecting pictures stored in sub folders. Please note that the snippet below is part of a larger script. When I run it, no errors are generated and everything works fine except for the match table (which gets created, but comes up empty every time). I'm using ArcGIS 10.5. and there is a field in the database table named "RadioCall" that has the same names as the pictures. The field is a 'string.'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;# Description: Creates an attachment match table for all files by walking through a set of subfolders&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;rootFolder = "W:\InventoryPhotos"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for folder in os.walk(rootFolder):&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;arcpy.GenerateAttachmentMatchTable_management(Fleetdata, folder[0], Matchtable, "RadioCall", ".jpg", "RELATIVE")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appreciated.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jul 2017 19:48:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/unable-to-generate-an-attachment-match-table-with/m-p/195112#M14963</guid>
      <dc:creator>MichaelTorbett</dc:creator>
      <dc:date>2017-07-11T19:48:39Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to generate an attachment match table with pictures stored in individual subfolders using python.</title>
      <link>https://community.esri.com/t5/python-questions/unable-to-generate-an-attachment-match-table-with/m-p/195113#M14964</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Michael,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="string token"&gt;"*.jpg"&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;Instead of just:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="string token"&gt;".jpg"&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;&lt;/P&gt;&lt;P&gt;Here is the updated line:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;GenerateAttachmentMatchTable_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Fleetdata&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; folder&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; Matchtable&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"RadioCall"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"*.jpg"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"RELATIVE"&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;&lt;/P&gt;&lt;P&gt;Also, this thread discusses this tool:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/thread/84001"&gt;Generate Attachment Match Table - Python script issue&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~Alex&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jul 2017 21:03:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/unable-to-generate-an-attachment-match-table-with/m-p/195113#M14964</guid>
      <dc:creator>AlexanderBrown5</dc:creator>
      <dc:date>2017-07-11T21:03:19Z</dc:date>
    </item>
  </channel>
</rss>

