Skip to main content
Solved

Writing JPEG Image to Geodatabase


Is it possible to write an image from a jpeg url into a file geodatabase? In other words, I want to store images directly from a url into a geodatabase. I need to extract the image from the url and move that image into a geodatabase. Thank you!

Best answer by takashi

Hi @shanezentner, the File Geodatabase format doesn't support saving image (raster) data directly, but it supports BLOB (Binary Large OBject) type so you can create the BLOB data for each JPEG image with the RasterExtractor transformer and then write it into a BLOB type field in the destination FGDB feature class. You can restore the original image from the BLOB data with the RasterReplacer transformer.

In addition, if you use the HTTPCaller transformer (Response Body Encoding: Binary) to get the JPEG image from its URL, the response body could be saved into the BLOB type field directly without using the RasterExtractor.

View original
This post is closed to further activity.
It may be a question with a best answer, an implemented idea, or just a post needing no comment.
If you have a follow-up or related question, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

takashi
Contributor
Forum|alt.badge.img+19
  • Contributor
  • April 28, 2017

Hi @shanezentner, the File Geodatabase format doesn't support saving image (raster) data directly, but it supports BLOB (Binary Large OBject) type so you can create the BLOB data for each JPEG image with the RasterExtractor transformer and then write it into a BLOB type field in the destination FGDB feature class. You can restore the original image from the BLOB data with the RasterReplacer transformer.

In addition, if you use the HTTPCaller transformer (Response Body Encoding: Binary) to get the JPEG image from its URL, the response body could be saved into the BLOB type field directly without using the RasterExtractor.


fme_can_do_it
Enthusiast
Forum|alt.badge.img+9

@takashiI am trying to perform a similar task with a feature class stored in an ArcSDE geodatabase. I have reviewed some tasks from an API, and I have image data stored in it. I want to write this image data into the feature class. Will this workaround work for writing to an ArcSDE feature class?


evieatsafe
Safer
Forum|alt.badge.img+18

@fme_can_do_it Yes, the BLOB workaround should also work for ArcSDE as well!


nordpil
Supporter
Forum|alt.badge.img+10
  • Supporter
  • February 10, 2025

@fme_can_do_it You might also consider using the attachments feature of geodatabases, which you can enable for featureclasses.

Here is some information:

https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/add-attachments.htm

https://support.safe.com/hc/en-us/articles/25407508005645-Writing-ArcGIS-Geodatabase-Attachments


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings