<?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: Displaying blobs in ArcGIS Viewer for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631746#M18747</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Is there no tool in FlexViewer that can currently read directly from a BLOB field and display an item such as a jpeg image that is stored in the BLOB format.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Like I mentioned before the ArcGIS Server REST API does not support BLOBs, and thus the Flex API cannot get to BLOBs.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;"the field values ... can be any of the standard JSON types - string, number and boolean."&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/rest/apiref/index.html?feature.html"&gt;http://resources.arcgis.com/en/help/rest/apiref/index.html?feature.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The preferred solution is to use attachments:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 May 2013 12:13:36 GMT</pubDate>
    <dc:creator>BjornSvensson</dc:creator>
    <dc:date>2013-05-14T12:13:36Z</dc:date>
    <item>
      <title>Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631733#M18734</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 mobile project running using ArcGIS mobile for Windows.&amp;nbsp; The project is being used by Trimble Junos - in order to allow the Trimbles to collect more than one picture in one location, I named the fields in the DB "Picture_1", ect.&amp;nbsp; This works great as it prompts the camera to open in the Trimble or add a photo that is already stored on the Trimble.&amp;nbsp; The problem I am having is adding the pictures directly into a Flex map so the Flex map is populated with data "live" from the field.&amp;nbsp; My current work flow is:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Copy the feature class to a personal geodatabase (since it is a Microsoft Access database)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-Run a script that extracts the blobs as jpegs to a folder&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-Have the Flex map call to that folder to display the images&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem with this is that the data does not feed live to the Flex map.&amp;nbsp; Any ideas?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Dustin Wiersma, GIS Analyst&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 May 2013 19:41:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631733#M18734</guid>
      <dc:creator>DustinWiersma2</dc:creator>
      <dc:date>2013-05-10T19:41:57Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631734#M18735</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I have a mobile project running using ArcGIS mobile for Windows...pictures&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That won't work because the server doesn't return BLOBs using the REST API (which is how Flex and other Web APIs connect to ArcGIS Server).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Instead of storing the images in BLOBs, you would need to use attachments (or files in folders like your batch script is doing now).&amp;nbsp; I don't know enough of the "trimble/mobile" aspect how to make that happen though...&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 May 2013 20:53:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631734#M18735</guid>
      <dc:creator>BjornSvensson</dc:creator>
      <dc:date>2013-05-10T20:53:29Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631735#M18736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the reply!&amp;nbsp; That is interesting about the rest point and blobs.&amp;nbsp; Unfortunately, the Trimbles do not use the attachment table for this project - other mobile projects do, such as mobile projects using the esri ArcGIS app.&amp;nbsp; For this project I need to have multiple photos for a single point, otherwise I could just use a field as a type raster.&amp;nbsp; So it sounds like I may need to develop a script that automates my current workflow.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 May 2013 21:00:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631735#M18736</guid>
      <dc:creator>DustinWiersma2</dc:creator>
      <dc:date>2013-05-10T21:00:30Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631736#M18737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I don't do mobile, but FLEX has issues accessing a local folder.&amp;nbsp; You normally need to set up a virtual directory on your server that points to the folder you are saving the jpegs in.&amp;nbsp; You can then access them using the URL in the flex viewer.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 15:19:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631736#M18737</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2013-05-13T15:19:45Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631737#M18738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rhett,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the reply!&amp;nbsp; That will be the work flow I will try to automate - have a script that extracts the blobs to jpegs in a folder on the server and have the Flex map point to that folder.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 15:31:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631737#M18738</guid>
      <dc:creator>DustinWiersma2</dc:creator>
      <dc:date>2013-05-13T15:31:11Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631738#M18739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Dustin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a similar workflow, with photos stored in BLOB fields and one to potentially many photos per feature.&amp;nbsp; The attachemnts feature doesn't really support 1:many so I have a python script that extracts the jpeg photos from the blob and saves them in a folder.&amp;nbsp; As it is writing the blobs, I capture the path and filename that I am saving them to (as well as my feature ID) and append to a list, then at the end of my script, I insertCursor the list to populate a FGDB table.&amp;nbsp; Now I not only have the jpeg stored local in a folder, I also have a ready-made table with all my paths ready to join/calculate to the feature class data that can be used for my link field.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Of course, I had to make a virtual directory on the server pointing to the folder I saved all my jpegs in, then had to go into IIS and, for that virtual folder, allow directory browsing as I often have many photos per site (if just one photo, my "path" actually points to the jpeg file, if more than one, it points to the folder.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This was kind of cluttery, especially for the sites with multiple photos, as IE doesn't give thumbnail views, so, all you see is a list of the somewhat cryptic filenames, and need to click on each photo to view it.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So, I took it one step farther.&amp;nbsp; After my python script extracts and saves the jpegs from the BOLBs, writes the "lookup table", joins/calculates the URL info to my feature class, it then runs a slightly modified version of pyGallery.&amp;nbsp; This creates a gallery for my photos similar to ( &lt;/SPAN&gt;&lt;A href="http://pygallery.sourceforge.net/samples/"&gt;http://pygallery.sourceforge.net/samples/&lt;/A&gt;&lt;SPAN&gt; ).&amp;nbsp; So now, if there is one photo, my popup says "Click for Photo", and it takes you direclty to the image viewed in a browser.&amp;nbsp; If there are more than one image, it says "Click for Photos", and if you click, it will take you to the index/thumbnail gallery page for that feature, with all the photos.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So far, not only the best way I've came up with for BLOBs, but also for one:many photos in Flex.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In case this gives you some ideas,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 16:14:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631738#M18739</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2013-05-13T16:14:36Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631739#M18740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Wow, that is quite the work flow.&amp;nbsp; That is exactly what I need to do.&amp;nbsp; Do you have the script written so it runs automatically on a time schedule?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 17:28:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631739#M18740</guid>
      <dc:creator>DustinWiersma2</dc:creator>
      <dc:date>2013-05-13T17:28:23Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631740#M18741</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Dustin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;With python and ArcGIS, I have found that it is normally best to execute all python scripts (at least scheduled ones) from a batch file. this way, once it is done with that particular script, since it was spawned in a separate python instance, it will then relsease all the "cryptic" locks it puts on the data and can move on to the next script.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So, if I have many scripts to run, I make one python script with a bunch of os.system(batchfilename) calls, will run the script, close the process, and move on.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;each batch file is similar to :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;cd C:\Python27\ArcGIS10.1

Python C:\arcgisserver\python\finish.py

pause

Exit&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Which sets the path to the python version I want to use, then executes the finish.py script, then exits when done.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;To schedule, I just use the windows scheduled tasks (task scheduler in Win 7) to run it on a nightly/weekly basis.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The "pause" in red I normally REM out, but is nice when developing so it doesn't just close the window down if it encounters an error.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Instead of the windows scheduler, I have used pyCRON in the past as well. Works like CRON on 'IX systems.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 16:43:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631740#M18741</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2021-12-12T16:43:12Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631741#M18742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rhett,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there any way you can share your python work flow for extracting the BLOB fields from a database to disk?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Alex&lt;/SPAN&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Dustin,&lt;BR /&gt;&lt;BR /&gt;I have a similar workflow, with photos stored in BLOB fields and one to potentially many photos per feature.&amp;nbsp; The attachemnts feature doesn't really support 1:many so I have a python script that extracts the jpeg photos from the blob and saves them in a folder.&amp;nbsp; As it is writing the blobs, I capture the path and filename that I am saving them to (as well as my feature ID) and append to a list, then at the end of my script, I insertCursor the list to populate a FGDB table.&amp;nbsp; Now I not only have the jpeg stored local in a folder, I also have a ready-made table with all my paths ready to join/calculate to the feature class data that can be used for my link field.&lt;BR /&gt;&lt;BR /&gt;Of course, I had to make a virtual directory on the server pointing to the folder I saved all my jpegs in, then had to go into IIS and, for that virtual folder, allow directory browsing as I often have many photos per site (if just one photo, my "path" actually points to the jpeg file, if more than one, it points to the folder.&lt;BR /&gt;&lt;BR /&gt;This was kind of cluttery, especially for the sites with multiple photos, as IE doesn't give thumbnail views, so, all you see is a list of the somewhat cryptic filenames, and need to click on each photo to view it.&lt;BR /&gt;&lt;BR /&gt;So, I took it one step farther.&amp;nbsp; After my python script extracts and saves the jpegs from the BOLBs, writes the "lookup table", joins/calculates the URL info to my feature class, it then runs a slightly modified version of pyGallery.&amp;nbsp; This creates a gallery for my photos similar to ( &lt;A href="http://pygallery.sourceforge.net/samples/"&gt;http://pygallery.sourceforge.net/samples/&lt;/A&gt; ).&amp;nbsp; So now, if there is one photo, my popup says "Click for Photo", and it takes you direclty to the image viewed in a browser.&amp;nbsp; If there are more than one image, it says "Click for Photos", and if you click, it will take you to the index/thumbnail gallery page for that feature, with all the photos.&lt;BR /&gt;&lt;BR /&gt;So far, not only the best way I've came up with for BLOBs, but also for one:many photos in Flex.&lt;BR /&gt;&lt;BR /&gt;In case this gives you some ideas,&lt;BR /&gt;&lt;BR /&gt;R_&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 18:30:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631741#M18742</guid>
      <dc:creator>AlexSanders</dc:creator>
      <dc:date>2013-05-13T18:30:34Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631742#M18743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Stuart/Alex,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here are the nuts and bolts of it:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is using the python that comes with 10.1 (v2.7.2).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;import arcpy, os from arcpy import da&amp;nbsp; inTable = "C:\\Connection to RCES_P.sde\\SIS_ADM.IMAGES"&amp;nbsp; #&amp;nbsp; table with identifier (SITE_CODE), imageID number (IMAGE_ID), and photo in BLOB field (PHOTO)&amp;nbsp; savepath = "\\\\mcflight01\\WebImages"&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #&amp;nbsp; initial path to save images/sub folders&amp;nbsp;&amp;nbsp; with da.SearchCursor(inTable,['SITE_CODE','IMAGE_ID','PHOTO']) as cursor: &amp;nbsp;&amp;nbsp; for row in cursor: &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SITE_CODE = str(row[0])&amp;nbsp;&amp;nbsp; # gets feature identifier from table&amp;nbsp; (SITE_CODE) as string &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fid = str(int(row[1]))&amp;nbsp;&amp;nbsp;&amp;nbsp; # gets ImageID from table (IMAGE_ID) as string without decimal point &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; binaryRep = row[2]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #&amp;nbsp; get photo from BLOB field as binaryRep variable &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; filename = (SITE_CODE.replace(':','_')).replace('/','')&amp;nbsp; + "_" + Fid + ".jpg"&amp;nbsp; # appends site_code to filename replacing : and /'s &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; folder = savepath + os.sep + SITE_CODE.replace(':','_')&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # appends site_code to folder replacing : with _&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if binaryRep: &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if not os.path.exists(folder): &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; os.system("mkdir " + '"' + folder + '"')&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # if doesn't already exist, make folder using folder variable &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; open(folder + os.sep&amp;nbsp; + filename, 'wb').write(binaryRep.tobytes())&amp;nbsp;&amp;nbsp;&amp;nbsp; # this actually saves the BLOB stored in binaryRep to filename variable&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; del binaryRep del row&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 20:33:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631742#M18743</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2013-05-13T20:33:29Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631743#M18744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for showing us how you coded this!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 20:55:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631743#M18744</guid>
      <dc:creator>DustinWiersma2</dc:creator>
      <dc:date>2013-05-13T20:55:08Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631744#M18745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You bet.&amp;nbsp; Here is where I got the initial information.&amp;nbsp; Also shows how to write to BLOB field as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://anothergisblog.blogspot.in/2012/06/working-with-blob-data-at-101-arcpyda.html"&gt;http://anothergisblog.blogspot.in/2012/06/working-with-blob-data-at-101-arcpyda.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 22:48:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631744#M18745</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2013-05-13T22:48:30Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631745#M18746</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rhett:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Does your script convert BLOB field data for individual records or does it convert BLOB field data for an entire feature class (or however the entire data set is stored)?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This seems like a duplication of file storage as the data is basically being stored in 2 different formats.&amp;nbsp; Is there no tool in FlexViewer that can currently read directly from a BLOB field and display an item such as a jpeg image that is stored in the BLOB format.&amp;nbsp; That seems like a more efficient system.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 11:52:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631745#M18746</guid>
      <dc:creator>MichaelVolz</dc:creator>
      <dc:date>2013-05-14T11:52:37Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631746#M18747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Is there no tool in FlexViewer that can currently read directly from a BLOB field and display an item such as a jpeg image that is stored in the BLOB format.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Like I mentioned before the ArcGIS Server REST API does not support BLOBs, and thus the Flex API cannot get to BLOBs.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;"the field values ... can be any of the standard JSON types - string, number and boolean."&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/rest/apiref/index.html?feature.html"&gt;http://resources.arcgis.com/en/help/rest/apiref/index.html?feature.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The preferred solution is to use attachments:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//01m90000000r000000&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:13:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631746#M18747</guid>
      <dc:creator>BjornSvensson</dc:creator>
      <dc:date>2013-05-14T12:13:36Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631747#M18748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Bjorn:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just to clarify, since the ArcGIS Server REST API does not support BLOBs, that would mean that any of the APIs would also not support BLOBs (e.g. Javascript API, Silverlight API and Flex API)?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there any chance that ESRI is looking to enhance these APIs with the ability to directly read/write to BLOB fields?&amp;nbsp; There are many 3rd party GIS software vendors that store data in BLOB fields and it would be very useful to be able to get directly to the data (plus it would reduce duplicated file storage).&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:29:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631747#M18748</guid>
      <dc:creator>MichaelVolz</dc:creator>
      <dc:date>2013-05-14T12:29:36Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631748#M18749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Just to clarify, since the ArcGIS Server REST API does not support BLOBs, that would mean that any of the APIs would also not support BLOBs (e.g. Javascript API, Silverlight API and Flex API)?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Correct.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;And since version 10.0, the best approach for relating images, pdf, word docs, pdf and pther files with a feature is to use "attachments".&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:37:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631748#M18749</guid>
      <dc:creator>BjornSvensson</dc:creator>
      <dc:date>2013-05-14T12:37:03Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631749#M18750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Michael,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; You should submit this enhancement request on the ArcGIS Ideas portal then and try to gain support from other to vote it up.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://ideas.arcgis.com/"&gt;http://ideas.arcgis.com/&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:38:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631749#M18750</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2013-05-14T12:38:26Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631750#M18751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Robert.&amp;nbsp; That is what I was planning to do, I just wanted to make sure I was not requesting an enhancement for a widget (tool) that was already available.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:55:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631750#M18751</guid>
      <dc:creator>MichaelVolz</dc:creator>
      <dc:date>2013-05-14T12:55:48Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631751#M18752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Rhett:&lt;BR /&gt;&lt;BR /&gt;Does your script convert BLOB field data for individual records or does it convert BLOB field data for an entire feature class (or however the entire data set is stored)?&lt;BR /&gt;&lt;BR /&gt;This seems like a duplication of file storage as the data is basically being stored in 2 different formats.&amp;nbsp; Is there no tool in FlexViewer that can currently read directly from a BLOB field and display an item such as a jpeg image that is stored in the BLOB format.&amp;nbsp; That seems like a more efficient system.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Michael,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My script works on a table (does not have to be a feature class) and&amp;nbsp; "extracts" whatever data is in the BLOB field for that record and saves it to a file.&amp;nbsp; Since I already know that all "objects" stored in my blob fields are jpegs, I name it with a .jpg on the end (could easily be a text file, or whatever in a BLOB, so you need to know what you are extracting).&amp;nbsp; The parts of my script I cut out actually look at what images have "changed", and re-extracts only them.&amp;nbsp; Can easilly add whatever logic you need to only extract what you want.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You are correct, it IS a duplication of data, but, is the best solution I have come up with and really doesn't put much of a dent in my 12 TB.&amp;nbsp; As far as server supporting BLOBs, the only BLOBs I know that are supported are attachments as they are stored as BLOBs in a FGDB.&amp;nbsp; Hopefully in the future, ESRI can extend that to non-ESRI BLOB fields as well.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have a simple 1:1 relationship, the attachments is probably the way to go, not to mention they automatically integrate with Flex popups.&amp;nbsp; Still a duplication of files, but they are tied to your data.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You could use something similar to my script to extract the images, then use the attachments script to load them directly into the FGDB as attachments without actually saving them locally.&amp;nbsp; However, the way attachments are currently, if you have a 1:many relationship with multiple features in a class, ALL attachments will be "linked" to the first feature in that class, and none of the others will have any attachments at all.&amp;nbsp; I have many photos, and potentially many features per class, so this is the route I chose.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There are several posts on the ideas page suggesting to improve the attachments tool to support a 1:many as well as to allow linking to a folder somewhere for attachemnts (this is a common one, as many people have their photos/etc. already saved somewhere, and don't want to have to copy them into the FGDB)&amp;nbsp; You may want to promote some of these.&amp;nbsp; I voted your latest one up as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;R_&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 14:06:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631751#M18752</guid>
      <dc:creator>RhettZufelt</dc:creator>
      <dc:date>2013-05-14T14:06:27Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying blobs</title>
      <link>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631752#M18753</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rhett,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That script worked perfectly that is exactly what we needed! Thank you so much for your help.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Alex Sanders&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 15:45:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-viewer-for-flex-questions/displaying-blobs/m-p/631752#M18753</guid>
      <dc:creator>AlexSanders</dc:creator>
      <dc:date>2013-05-14T15:45:30Z</dc:date>
    </item>
  </channel>
</rss>

