Midrange News for the IBM i Community


Posted by: clbirk
blobs in db2?
has no ratings.
Published: 11 Sep 2012
Revised: 23 Jan 2013 - 3969 days ago
Last viewed on: 04 Dec 2023 (4772 views) 

Using IBM i? Need to create Excel, CSV, HTML, JSON, PDF, SPOOL reports? Learn more about the fastest and least expensive tool for the job: SQL iQuery.

blobs in db2? Published by: clbirk on 11 Sep 2012 view comments(2)

configured a table in a schema with a blob of about 20,000 bytes. Whenever a SELECT is issued against the table, it blows up/fails. Changed to varchar and it works fine...

 

I assume there are some restrictions for blobs?

Return to midrangenews.com home page.
Sort Ascend | Descend

COMMENTS

(Sign in to Post a Comment)
Posted by: bobcozzi
Site Admin ****
Chicagoland
Comment on: blobs in db2?
Posted: 11 years 2 months 25 days 14 hours 10 minutes ago

Right. You have to define the field receiving the BLOB on the D spec, and specify:

D myField      S             SQL_BLOB( varName : 20000)
Posted by: RalphAMiller
Premium member *
Franklin, TN
Comment on: blobs in db2?
Posted: 11 years 2 months 10 days 21 hours 46 minutes ago

Lessons learned while watching the Steve McQueen movie has caused me to refrain from using Blobs. Better safe than sorry, right?