<?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: Script to batch process adding raster datasets as attributes in a feature class in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724906#M56189</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks! This helps a ton!&amp;nbsp; I tried to following script, and it doesn't generate any errors, but I also don't see any sign of the pictures being associated with the points. When I use the Identify tool there is no image.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;###Adding attachments to geodatabase

import csv
import arcpy
import os
import sys

input = r"Y:/Data/practice_shape/Practice.gdb/test"
inputField = "OBJECTID"
matchTable = r"Y:/Data/practice_shape/Practice.gdb/test"
matchField = "OBJECTID"
pathField = "Image" 
picFolder = r"Y:/Data/practice_shape/images"


try:
&amp;nbsp;&amp;nbsp;&amp;nbsp; # enable GDB attachments
 arcpy.EnableAttachments_management(input)

&amp;nbsp;&amp;nbsp;&amp;nbsp; # add attachments tool
 arcpy.AddAttachments_management(input, inputField, matchTable, matchField, pathField, picFolder)

except:
 print arcpy.GetMessages(2)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 06:59:52 GMT</pubDate>
    <dc:creator>RebeccaCotteleer</dc:creator>
    <dc:date>2021-12-12T06:59:52Z</dc:date>
    <item>
      <title>Script to batch process adding raster datasets as attributes in a feature class</title>
      <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724904#M56187</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello, All.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a large set of point features (signs locations) that I would like to add images to. I have the sign feature class in a Geodatabase and I know how to add the images manually one at a time. I think the easiest way to handle this would be to create a field that contains the filepaths for the images (so each cell would read "C:/Data/images/IDnumber.jpg", with IDnumber being unique for each feature), but I don't know how to write the code to use the file path to import the images into the raster field in the feature class.&amp;nbsp; I'm new to python in general, but can work with code if someone give me an idea of how to format it. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help would be greatly appreciated! Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Apr 2014 14:49:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724904#M56187</guid>
      <dc:creator>RebeccaCotteleer</dc:creator>
      <dc:date>2014-04-07T14:49:27Z</dc:date>
    </item>
    <item>
      <title>Re: Script to batch process adding raster datasets as attributes in a feature class</title>
      <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724905#M56188</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The geodatabase offers the "Attachments" management classes to manage images associated to features/feature classes. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="http://resources.arcgis.com/en/help/main/10.1/index.html#//00170000014v000000" rel="nofollow" target="_blank"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//00170000014v000000&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, Xander has a good example in this thread: &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://forums.arcgis.com/threads/96729-Generate-Attachment-Match-Table-Python-script-issue?highlight=attachment" rel="nofollow" target="_blank"&gt;http://forums.arcgis.com/threads/96729-Generate-Attachment-Match-Table-Python-script-issue?highlight=attachment&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Apr 2014 15:09:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724905#M56188</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2014-04-07T15:09:31Z</dc:date>
    </item>
    <item>
      <title>Re: Script to batch process adding raster datasets as attributes in a feature class</title>
      <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724906#M56189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks! This helps a ton!&amp;nbsp; I tried to following script, and it doesn't generate any errors, but I also don't see any sign of the pictures being associated with the points. When I use the Identify tool there is no image.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;###Adding attachments to geodatabase

import csv
import arcpy
import os
import sys

input = r"Y:/Data/practice_shape/Practice.gdb/test"
inputField = "OBJECTID"
matchTable = r"Y:/Data/practice_shape/Practice.gdb/test"
matchField = "OBJECTID"
pathField = "Image" 
picFolder = r"Y:/Data/practice_shape/images"


try:
&amp;nbsp;&amp;nbsp;&amp;nbsp; # enable GDB attachments
 arcpy.EnableAttachments_management(input)

&amp;nbsp;&amp;nbsp;&amp;nbsp; # add attachments tool
 arcpy.AddAttachments_management(input, inputField, matchTable, matchField, pathField, picFolder)

except:
 print arcpy.GetMessages(2)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 06:59:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724906#M56189</guid>
      <dc:creator>RebeccaCotteleer</dc:creator>
      <dc:date>2021-12-12T06:59:52Z</dc:date>
    </item>
    <item>
      <title>Re: Script to batch process adding raster datasets as attributes in a feature class</title>
      <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724907#M56190</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Thanks! This helps a ton!&amp;nbsp; I tried to following script, and it doesn't generate any errors, but I also don't see any sign of the pictures being associated with the points. When I use the Identify tool there is no image.&lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Just to clarify, you do not see a the little attachment paper clip icon in the identify dialog?&amp;nbsp; To verify you can use the HTML pop up instead of the identify tool as the result will have the image in the dialog popup instead of having to click the attachment.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, check the Geodatabase itself for the __ATTACH table and it's associated RelationshipClass.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;One last thing: have you attempted to manually setup Attachments instead of with Python code?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 10:55:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724907#M56190</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2014-04-08T10:55:15Z</dc:date>
    </item>
    <item>
      <title>Re: Script to batch process adding raster datasets as attributes in a feature class</title>
      <link>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724908#M56191</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the reply.&amp;nbsp; After looking back to the ESRI page on the process, I realized that my problem was working on a machine with only a Basic License. My oops. Thanks for the help!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 19:36:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-to-batch-process-adding-raster-datasets-as/m-p/724908#M56191</guid>
      <dc:creator>RebeccaCotteleer</dc:creator>
      <dc:date>2014-04-08T19:36:01Z</dc:date>
    </item>
  </channel>
</rss>

