RE: BLOBs

"Birgitta Hauser" <Hauser-bRAHsVz2yv4TVIZRl6KS/[email protected]> Tue, 16 Jun 2026 06:22:15 +0200
Newsgroups gmane.comp.hardware.ibm.midrange
Message-ID <[email protected]>
It is "GET_BLOB_FROM_FILE" ... and the function has to be run under commitment control

Mit freundlichen Grüßen / Best regards

Birgitta Hauser
Modernization – Education – Consulting on IBM i
Database and Software Architect  
IBM Champion since 2020

"Shoot for the moon, even if you miss, you'll land among the stars." (Les Brown)
"If you think education is expensive, try ignorance." (Derek Bok)
"What is worse than training your staff and losing them? Not training them and keeping them!"
"Train people well enough so they can leave, treat them well enough so they don't want to. " (Richard Branson)
"Learning is experience … everything else is only information!" (Albert Einstein)


-----Original Message-----
From: MIDRANGE-L <[email protected]> On Behalf Of James H. H. Lampert via MIDRANGE-L
Sent: Tuesday, 16 June 2026 01:13
To: Midrange Systems Technical Discussion <[email protected]>
Cc: James H. H. Lampert <[email protected]>
Subject: Re: BLOBs

On 6/15/26 1:33 PM, Daniel Gross wrote:
> Like this:
> 
> exec sql insert into ... (
>     ...,
>     blobField => get_blob_from_file(:fileName),
>     ...
> );
> 
> (This is new INSERT syntax)
> 
> HTH
> Daniel

Hmm. What is the context on the above?

In both iACS "Run SQL Scripts," if I try to use http_get_blob, according to the docs, I get

> Message: [SQL0204] HTTP_GET_BLOB in *LIBL type *N not found.

If I try to use get_blob_from_file, iACS comes back with

> Message: [SQL0443] LOB and XML locators are not allowed with COMMIT(*NONE).

even if I try it on a file in a journaled library, and STRSQL doesn't even get that far.

The exact statement that I tried in iACS is:

> insert into jlib.blobtest1 values(123, 
> get_blob_from_file('/lob1.png'));

where "/lob1.png" is a file sitting in the IFS root, jlib is a library that is journaled.

--
JHHL
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: [email protected] To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: [email protected]
Before posting, please take a moment to review the archives at https://archive.midrange.com/midrange-l.

Please contact [email protected] for any subscription related questions.

-- 
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: [email protected]
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: [email protected]
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact [email protected] for any subscription related questions.