using blobs with cobol?

John Cops

using blobs with cobol?
I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

Does anybody have any samples i can see that show how to set up everything
from the column definitions to using the table and auxiliary table??

Once again, this will be done in cobol.

Thanks in advance

John Cops



Craig Wahlmeier

Re: using blobs with cobol?
(in response to John Cops)
John,

Is this mainframe COBOL or non-mainframe? We have plenty of Microfocus
COBOL running on Windows XX that uses BLOBs on DB2 for Windows NT. If you
want some code, I'll send it...

Craig Wahlmeier
Senior Technical Administrator - Database Systems
Data-Tronics Corp.


-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Tuesday, February 27, 2001 9:27 AM
To: [login to unmask email]
Subject: using blobs with cobol?


I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

Does anybody have any samples i can see that show how to set up everything
from the column definitions to using the table and auxiliary table??

Once again, this will be done in cobol.

Thanks in advance

John Cops








John Cops

Re: using blobs with cobol?
(in response to Craig Wahlmeier)
this is on a mainframe. how different is the code?

thanks
John




Craig Wahlmeier
<[login to unmask email] To: [login to unmask email]
ONICS.COM> cc:
Sent by: DB2 Data Fax to:
Base Discussion Subject: Re: using blobs with cobol?
List
<[login to unmask email]>


02/27/2001 11:08 AM
Please respond to
DB2 Data Base
Discussion List






John,

Is this mainframe COBOL or non-mainframe? We have plenty of Microfocus
COBOL running on Windows XX that uses BLOBs on DB2 for Windows NT. If you
want some code, I'll send it...

Craig Wahlmeier
Senior Technical Administrator - Database Systems
Data-Tronics Corp.


-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Tuesday, February 27, 2001 9:27 AM
To: [login to unmask email]
Subject: using blobs with cobol?


I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

Does anybody have any samples i can see that show how to set up everything
from the column definitions to using the table and auxiliary table??

Once again, this will be done in cobol.

Thanks in advance

John Cops



the










James Campbell

Re: using blobs with cobol?
(in response to John Cops)
The following is from a variety of sources, and sometimes refers to other
mails which are not included here. It specifically refers to CLOBs, but
programming BLOBs is the same - except there is no CCSID translation.
<DDL stuff>
CREATE LOB TABLESPACE xxxxxxxx IN DBAAAAAA USING STOGROUP ....
BUFFERPOOL BPy
LOCKSIZE LOB
LOG NO ;
CREATE TABLESPACE yyyyyyyy IN DBAAAAAA USING STOGROUP ....
BUFFERPOOL BP1
LOCKSIZE PAGE
CCSID EBCDIC ;
(Note read the Admin Guide guidelines on assigning a tablespace to a
bufferpool. Don't use a "non LOB" buffer pool, and set DWQT to zero)

CREATE TABLE stuff
(KEY INTEGER NOT NULL
,ROWID ROWID GENERATED ALWAYS
-- must have a rowid column
,CLOBDATA CLOB(10M)
,PRIMARY KEY (KEY) )
IN DBAAAAAA.yyyyyyyy ;
CREATE AUXILIARY TABLE stuff_clob
IN DBAAAAAA.xxxxxxxx
STORES stuff
COLUMN CLOBDATA;
CREATE UNIQUE INDEX iiiiiiii ON stuff_clob
--- note, no column name specified
USING STOGROUP ....

;
(and, of course, an index on stuff.key)

<programming stuff>

Congratulations. To quote from the DB2 Technical Update "programming LOBs
is challenging". I'm sure you enjoy the experience. :-;

You should read the Appl Prog Guide Chapter 4.2 Programming for large
objects (LOBs). You should also have been given a copy of the following
(which I've changed to be CLOB and static allocation orientated). I'll
expand the comments a bit.

01 CLOB-LOC1 USAGE IS SQL TYPE IS CLOB_LOCATOR.
* The precompiler will generate the following in the actual program:
* 01 CLOB-LOC1 PIC S9(9) USAGE IS BINARY.
* however, it is really for internal use only

01 CLOB-DATA USAGE IS SQL TYPE IS CLOB 32767.
* The precompiler will generate the following:
* 01 CLOB-DATA.
* 05 CLOB-DATA-LENGTH PIC S9(9) COMP.
* 05 CLOB-DATA-DATA PIC X(32767).
* and db2 handles it much like any varying length string - except it can be
longer than 32k.

* somewhere to store the total length of a clob column
... CLOB-DATA-TOTAL-LENGTH PIC S9(9) COMP.
...
PROCEDURE DIVISION.
...
* this bit of code inserts data into the clob
* .first hand some data to db2
* .. first tell db2 how much data we are providing in the following SET
statement
MOVE length-of-some-data TO CLOB-DATA-LENGTH
* .. now give it the actual data. The length of "some-data" was give in the
previous move
MOVE some-data TO CLOB-DATA-DATA
* .. now tell db2 about the data. Note that this does not do the insert
EXEC SQL
SET :CLOB-LOC1 = :CLOB-DATA
END-EXEC
* .now concatenate some more data to what we just gave
MOVE length-of-some-more-data TO CLOB-DATA-LENGTH
MOVE some-more-data TO CLOB-DATA-DATA
* .. concatenate the data to what we previously handed over
EXEC SQL
SET :CLOB-LOC1 = :CLOB-LOC1 || :CLOB-DATA
END-EXEC
* .repeat until all data has been handed over
* .now insert the data into the table
EXEC SQL
INSERT INTO STUFF (..., CLOBDATA , ...)
VALUES(..., :CLOB-LOC1, ...)
END-EXEC
...

* this next bit of code retrieves clob data into the program
EXEC SQL
SELECT ..., CLOBTDATA, ...
INTO ..., :CLOB-LOC1, ...
FROM STUFF
WHERE ...
END-EXEC
* this actually sets the _locator_ to point to the clob data. This clob
data is not yet
* available to the program.

* now actually move the data into the program's data area
* first note how long the clob data is in total
EXEC SQL
SET :CLOB-DATA-TOTAL-LENGTH = LENGTH(:CLOB-LOC1)
END-EXEC
* having decided to move a range of bytes into the program - hopefully not
more than
* the length of the clob data variable (you should ensure that
* start-position+length-of-data-1 <= CLOB-DATA-TOTAL-LENGTH,
* otherwise db2 will pad the data in clob-data-data.
EXEC SQL
SET :CLOB-DATA = SUBSTR(:CLOB-LOC1,start-position,length-of-data)
END-EXEC
* at this time CLOB-DATA-LENGTH will be 'length-of-data' and the first
<clob-data-length>
* bytes of CLOB-DATA-DATA will be the retrieved data
...

* finally, a FREE is not strictly required, but it does release DB2 storage
used, so
* helps system performance.
EXEC SQL
FREE LOCATOR :CLOB-LOC1
END-EXEC

So, to answer you explicit questions
1) yes - it should work fine
2) there are no problems in using any length you like in the 'USAGE IS SQL
TYPE IS CLOB' phrase. If, however, you use more than 32767, the variable
CLOB-DATA-DATA will actually be a group variable, with lower level fillers
to get the required length.
3) answered in comments above.
4) Correct. SUBSTR will not translate data.

HTH, and let me know how things go.

=====

No, the size in the SQL TYPE IS CLOB is the size of the program's data area
to work on the clob. (It can be larger than the actual amount you'll be
working on, so specifying 32767 but only ever using 31000 is OK.) You use
the SET statements to copy data from this area into the clob, or from the
clob into this area. Much like a windowing operation: the clob is what is
windowed, the data area is the window.

I have realised that one other operation you might need to do is to insert
data into the middle of a clob. To do this, you'ld do something like:

* populate locator
EXEC SQL SELECT clob-column INTO :hv-clob-loc FROM .... WHERE ... END-EXEC

* get some actual data out of clob
EXEC SQL SET :hv-clob-var = SUBSTR(:hv-clob-loc,extract-start,extract-len)
END-EXEC

* update data in program
MOVE updated-data-len TO hv-clob-var-LENGTH
MOVE updated-data TO hv-clob-var-DATA

* update located data
EXEC SQL SET :hv-clob-loc = SUBSTR(:hv-clob-loc,1,extract-start - 1) ||
:hv-clob-var ||
SUBSTR(:hv-clob-loc,extract-start +
extract-len,LENGTH(:hv-clob-loc) - extract-start - extract-len + 1)
END-EXEC
I must confess I am not certain about this last bit of SQL. The examples I
have seen use two locators to do it:
EXEC SQL SET :hv-clob-loc-2 = SUBSTR(:hv-clob-loc,1,extract-start - 1) ||
:hv-clob-var ||
SUBSTR(:hv-clob-loc,extract-start +
extract-len,LENGTH(:hv-clob-loc) - extract-start - extract-len + 1)
END-EXEC
EXEC SQL SET :hv-clob-loc = :hv-clob-loc-2 END-EXEC
but I haven't found an explicit statement that means you cannot do it the
first way. Try and see.

* update data in table
EXEC SQL UPDATE .... SET clob-column = :hv-clob-loc WHERE ... END-EXEC

HTH
/* standard disclaimer */
James Campbell
Hansen Corporation
-----Original Message-----
I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

<rest snipped to make message less than 250 lines>



Craig Wahlmeier

Re: using blobs with cobol?
(in response to James Campbell)
John,

Can't speak to how different the code is. We are running DB2 V5 on the
mainframe and therefore have no blobs or COBOL code that uses blobs. We
used the NT platform for the imaging systems we wrote. (Disk space is much
cheaper than mainframe...)

Let me know if you want it anyway.

Craig

-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Tuesday, February 27, 2001 11:18 AM
To: [login to unmask email]
Subject: Re: using blobs with cobol?


this is on a mainframe. how different is the code?

thanks
John




Craig Wahlmeier
<[login to unmask email] To: [login to unmask email]
ONICS.COM> cc:
Sent by: DB2 Data Fax to:
Base Discussion Subject: Re: using blobs
with cobol?
List
<[login to unmask email]>


02/27/2001 11:08 AM
Please respond to
DB2 Data Base
Discussion List






John,

Is this mainframe COBOL or non-mainframe? We have plenty of Microfocus
COBOL running on Windows XX that uses BLOBs on DB2 for Windows NT. If you
want some code, I'll send it...

Craig Wahlmeier
Senior Technical Administrator - Database Systems
Data-Tronics Corp.


-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Tuesday, February 27, 2001 9:27 AM
To: [login to unmask email]
Subject: using blobs with cobol?


I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

Does anybody have any samples i can see that show how to set up everything
from the column definitions to using the table and auxiliary table??

Once again, this will be done in cobol.

Thanks in advance

John Cops



the















John Cops

Re: using blobs with cobol?
(in response to Craig Wahlmeier)
James

If i am going to be storing a pdf that is > 32767, does this mean i have to
somehow break it up into parts that will fit in this clob-data-data ( )?
and then concatenate them back together when i want to use it?

also, what about setting both the table and auxiliary table for use with
various utilities? (i.e. specifying position (from, to) etc)

thanks for the info
John




James Campbell
<[login to unmask email] To: [login to unmask email]
RP.COM.AU> cc:
Sent by: DB2 Data Fax to:
Base Discussion List Subject: Re: using blobs with cobol?
<[login to unmask email]>


02/27/2001 10:58 PM
Please respond to DB2
Data Base Discussion
List






The following is from a variety of sources, and sometimes refers to other
mails which are not included here. It specifically refers to CLOBs, but
programming BLOBs is the same - except there is no CCSID translation.
<DDL stuff>
CREATE LOB TABLESPACE xxxxxxxx IN DBAAAAAA USING STOGROUP ....
BUFFERPOOL BPy
LOCKSIZE LOB
LOG NO ;
CREATE TABLESPACE yyyyyyyy IN DBAAAAAA USING STOGROUP ....
BUFFERPOOL BP1
LOCKSIZE PAGE
CCSID EBCDIC ;
(Note read the Admin Guide guidelines on assigning a tablespace to a
bufferpool. Don't use a "non LOB" buffer pool, and set DWQT to zero)

CREATE TABLE stuff
(KEY INTEGER NOT NULL
,ROWID ROWID GENERATED ALWAYS
-- must have a rowid column
,CLOBDATA CLOB(10M)
,PRIMARY KEY (KEY) )
IN DBAAAAAA.yyyyyyyy ;
CREATE AUXILIARY TABLE stuff_clob
IN DBAAAAAA.xxxxxxxx
STORES stuff
COLUMN CLOBDATA;
CREATE UNIQUE INDEX iiiiiiii ON stuff_clob
--- note, no column name specified
USING STOGROUP ....

;
(and, of course, an index on stuff.key)

<programming stuff>

Congratulations. To quote from the DB2 Technical Update "programming LOBs
is challenging". I'm sure you enjoy the experience. :-;

You should read the Appl Prog Guide Chapter 4.2 Programming for large
objects (LOBs). You should also have been given a copy of the following
(which I've changed to be CLOB and static allocation orientated). I'll
expand the comments a bit.

01 CLOB-LOC1 USAGE IS SQL TYPE IS CLOB_LOCATOR.
* The precompiler will generate the following in the actual program:
* 01 CLOB-LOC1 PIC S9(9) USAGE IS BINARY.
* however, it is really for internal use only

01 CLOB-DATA USAGE IS SQL TYPE IS CLOB 32767.
* The precompiler will generate the following:
* 01 CLOB-DATA.
* 05 CLOB-DATA-LENGTH PIC S9(9) COMP.
* 05 CLOB-DATA-DATA PIC X(32767).
* and db2 handles it much like any varying length string - except it can be
longer than 32k.

* somewhere to store the total length of a clob column
... CLOB-DATA-TOTAL-LENGTH PIC S9(9) COMP.
...
PROCEDURE DIVISION.
...
* this bit of code inserts data into the clob
* .first hand some data to db2
* .. first tell db2 how much data we are providing in the following SET
statement
MOVE length-of-some-data TO CLOB-DATA-LENGTH
* .. now give it the actual data. The length of "some-data" was give in
the
previous move
MOVE some-data TO CLOB-DATA-DATA
* .. now tell db2 about the data. Note that this does not do the insert
EXEC SQL
SET :CLOB-LOC1 = :CLOB-DATA
END-EXEC
* .now concatenate some more data to what we just gave
MOVE length-of-some-more-data TO CLOB-DATA-LENGTH
MOVE some-more-data TO CLOB-DATA-DATA
* .. concatenate the data to what we previously handed over
EXEC SQL
SET :CLOB-LOC1 = :CLOB-LOC1 || :CLOB-DATA
END-EXEC
* .repeat until all data has been handed over
* .now insert the data into the table
EXEC SQL
INSERT INTO STUFF (..., CLOBDATA , ...)
VALUES(..., :CLOB-LOC1, ...)
END-EXEC
...

* this next bit of code retrieves clob data into the program
EXEC SQL
SELECT ..., CLOBTDATA, ...
INTO ..., :CLOB-LOC1, ...
FROM STUFF
WHERE ...
END-EXEC
* this actually sets the _locator_ to point to the clob data. This clob
data is not yet
* available to the program.

* now actually move the data into the program's data area
* first note how long the clob data is in total
EXEC SQL
SET :CLOB-DATA-TOTAL-LENGTH = LENGTH(:CLOB-LOC1)
END-EXEC
* having decided to move a range of bytes into the program - hopefully not
more than
* the length of the clob data variable (you should ensure that
* start-position+length-of-data-1 <= CLOB-DATA-TOTAL-LENGTH,
* otherwise db2 will pad the data in clob-data-data.
EXEC SQL
SET :CLOB-DATA = SUBSTR(:CLOB-LOC1,start-position,length-of-data)
END-EXEC
* at this time CLOB-DATA-LENGTH will be 'length-of-data' and the first
<clob-data-length>
* bytes of CLOB-DATA-DATA will be the retrieved data
...

* finally, a FREE is not strictly required, but it does release DB2 storage
used, so
* helps system performance.
EXEC SQL
FREE LOCATOR :CLOB-LOC1
END-EXEC

So, to answer you explicit questions
1) yes - it should work fine
2) there are no problems in using any length you like in the 'USAGE IS SQL
TYPE IS CLOB' phrase. If, however, you use more than 32767, the variable
CLOB-DATA-DATA will actually be a group variable, with lower level fillers
to get the required length.
3) answered in comments above.
4) Correct. SUBSTR will not translate data.

HTH, and let me know how things go.

=====

No, the size in the SQL TYPE IS CLOB is the size of the program's data area
to work on the clob. (It can be larger than the actual amount you'll be
working on, so specifying 32767 but only ever using 31000 is OK.) You use
the SET statements to copy data from this area into the clob, or from the
clob into this area. Much like a windowing operation: the clob is what is
windowed, the data area is the window.

I have realised that one other operation you might need to do is to insert
data into the middle of a clob. To do this, you'ld do something like:

* populate locator
EXEC SQL SELECT clob-column INTO :hv-clob-loc FROM .... WHERE ... END-EXEC

* get some actual data out of clob
EXEC SQL SET :hv-clob-var = SUBSTR(:hv-clob-loc,extract-start,extract-len)
END-EXEC

* update data in program
MOVE updated-data-len TO hv-clob-var-LENGTH
MOVE updated-data TO hv-clob-var-DATA

* update located data
EXEC SQL SET :hv-clob-loc = SUBSTR(:hv-clob-loc,1,extract-start - 1) ||
:hv-clob-var ||
SUBSTR(:hv-clob-loc,extract-start +
extract-len,LENGTH(:hv-clob-loc) - extract-start - extract-len + 1)
END-EXEC
I must confess I am not certain about this last bit of SQL. The examples I
have seen use two locators to do it:
EXEC SQL SET :hv-clob-loc-2 = SUBSTR(:hv-clob-loc,1,extract-start - 1) ||
:hv-clob-var ||
SUBSTR(:hv-clob-loc,extract-start +
extract-len,LENGTH(:hv-clob-loc) - extract-start - extract-len + 1)
END-EXEC
EXEC SQL SET :hv-clob-loc = :hv-clob-loc-2 END-EXEC
but I haven't found an explicit statement that means you cannot do it the
first way. Try and see.

* update data in table
EXEC SQL UPDATE .... SET clob-column = :hv-clob-loc WHERE ... END-EXEC

HTH
/* standard disclaimer */
James Campbell
Hansen Corporation
-----Original Message-----
I am attempting to store pdf's in a table using the blob definition. I am
the first to attempt this in our shop so i am pretty lost. After going
over the manual and contacting ibm, the best info i have received is
cryptic at best.

<rest snipped to make message less than 250 lines>








James Campbell

Re: using blobs with cobol?
(in response to John Cops)
John

If you had:
01 CLOB-DATA USAGE IS SQL TYPE IS CLOB 65535.
DB2 will generate:
01 CLOB-DATA.
05 CLOB-DATA-LENGTH PIC S9(9) COMP.
05 CLOB-DATA-DATA.
07 FILLER PIC X(32767).
07 FILLER PIC X(32767).
07 FILLER PIC X(1).
(Appl Prog and SQL Guide has examples of the various COBOL structures
generated.)

How you choose to populate the group item CLOB-DATA-DATA is your affair, but
DB2 sees it as a four byte length field followed by the appropriate number
of bytes. (Double bytes if it was a DBCLOB.)

Which "various" utilities? As a previous thread revealed, you cannot use
LOAD (or REORG UNLOAD EXTERNAL or DSNTIAUL) on LOB columns where the total
external length can be greater than 32767 bytes. Other utilities (really
REORG, RUNSTATS) tend to use tablespace names - these you need to run on the
base and any LOB spaces as separate utilities.

/* standard disclaimer */
James Campbell
Hansen Corporation
-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Thursday, 1 March 2001 7:58
To: [login to unmask email]
Subject: Re: [DB2-L] using blobs with cobol?


James

If i am going to be storing a pdf that is > 32767, does this mean i have to
somehow break it up into parts that will fit in this clob-data-data ( )?
and then concatenate them back together when i want to use it?

also, what about setting both the table and auxiliary table for use with
various utilities? (i.e. specifying position (from, to) etc)

thanks for the info
John



John Cops

using blobs with cobol?
(in response to James Campbell)
i am using db2 with cobol on an os/390.

i am attempting to read a file which contains a pdf and then insert it into
a table using blobs.

i have put these in working storage just prior to my include sql
statements:

01 ETEPDF-J-PDF USAGE IS
SQL TYPE IS BLOB(1M).

01 PDF-LOC USAGE IS
SQL TYPE IS BLOB_LOCATOR.


when i try to use these, i get "undefined or unusable host variable" ?????

also, when i read the pdf from the file, am i supposed to just read into
etepdf-j-pdf????


any help would be greatly appreciated.

thanks
John



James Campbell

Re: using blobs with cobol?
(in response to John Cops)
Could you also post the SQL that uses these?

-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Friday, 9 March 2001 2:38
To: [login to unmask email]
Subject: [DB2-L] using blobs with cobol?


i am using db2 with cobol on an os/390.

i am attempting to read a file which contains a pdf and then insert it into
a table using blobs.

i have put these in working storage just prior to my include sql
statements:

01 ETEPDF-J-PDF USAGE IS
SQL TYPE IS BLOB(1M).

01 PDF-LOC USAGE IS
SQL TYPE IS BLOB_LOCATOR.


when i try to use these, i get "undefined or unusable host variable" ?????

also, when i read the pdf from the file, am i supposed to just read into
etepdf-j-pdf????


any help would be greatly appreciated.

thanks
John








John Cops

Re: using blobs with cobol?
(in response to James Campbell)
here is my insert statement:


EXEC SQL
INSERT INTO HET.ENDOR_PDF
( N_ENDOR,
D_EDITION,
I_ROW,
J_PDF
)
VALUES
(:ETEPDF-N-ENDOR,
:ETEPDF-D-EDITION,
:ETEPDF-I-ROW,
:ETEPDF-J-PDF-DATA
)
END-EXEC.
*
here is my dclgen:
EXEC SQL DECLARE HET.ENDOR_PDF TABLE
( N_ENDOR CHAR(8) NOT NULL,
D_EDITION DATE NOT NULL,
I_ROW ROWID NOT NULL,
J_PDF BLOB(1048576)
) END-EXEC.
****************************************************************
* COBOL DECLARATION FOR TABLE HET.ENDOR_PDF
****************************************************************
01 DCLENDOR-PDF.
10 ETEPDF-N-ENDOR PIC X(8).
10 ETEPDF-D-EDITION PIC X(10).
10 ETEPDF-I-ROW USAGE SQL TYPE IS ROWID.
10 ETEPDF-J-PDF USAGE SQL TYPE IS BLOB-LOCATOR.
****************************************************************

also, if i am to read into the blob field, what am i supposed to put in my
FD for my input file?

thanks
John




James Campbell
<[login to unmask email] To: [login to unmask email]
RP.COM.AU> cc:
Sent by: DB2 Data Fax to:
Base Discussion List Subject: Re: using blobs with cobol?
<[login to unmask email]>


03/08/2001 09:39 PM
Please respond to DB2
Data Base Discussion
List






Could you also post the SQL that uses these?

-----Original Message-----
From: John Cops [mailto:[login to unmask email]
Sent: Friday, 9 March 2001 2:38
To: [login to unmask email]
Subject: [DB2-L] using blobs with cobol?


i am using db2 with cobol on an os/390.

i am attempting to read a file which contains a pdf and then insert it into
a table using blobs.

i have put these in working storage just prior to my include sql
statements:

01 ETEPDF-J-PDF USAGE IS
SQL TYPE IS BLOB(1M).

01 PDF-LOC USAGE IS
SQL TYPE IS BLOB_LOCATOR.


when i try to use these, i get "undefined or unusable host variable" ?????

also, when i read the pdf from the file, am i supposed to just read into
etepdf-j-pdf????


any help would be greatly appreciated.

thanks
John



the










Karl Sniderman

Using LOBs
(in response to John Cops)
I need lots of help. First of all I am confused about UDB. We are running
DB2 V6 on MVS (OS/390). Is this UDB?
The reason I am confused is we may have a need for BLOB's to store images.
When I start reading about LOBs I see statements like "The system
administrator enables the database server for use by the Image Extender"
Does "server" mean that this can't be done in MVS? If NOT, then what is
meant by "the db2ext command-line processor"?
I will appreciate some help for a rookie.
Karl Sniderman
BlueCross BlueShield of Oklahoma



Kirk Hampton

Re: Using LOBs
(in response to Karl Sniderman)
Hi Karl,
DB2 Version 6 on OS/390 is indeed called UDB, and does support
LOB's, and I have seen references to "server" even though it is running on
OS/390. But as far as I know, there is no db2ext command-line processor
on OS/390, that would be on Unix/Windows/OS2.

Kirk Hampton
DB2 OS/390 Sysprog
IBM Certified Solutions Expert - DB2 V7 Database Administration OS/390
TXU Energy Services
Dallas, Texas





"Sniderman, Karl" <[login to unmask email]> on 12/20/2001 01:35:45 PM

Please respond to DB2 Data Base Discussion List <[login to unmask email]>

To: [login to unmask email]
cc: (bcc: Kirk Hampton/BIZSRV/TXU)
Subject: Using LOBs



I need lots of help. First of all I am confused about UDB. We are running
DB2 V6 on MVS (OS/390). Is this UDB?
The reason I am confused is we may have a need for BLOB's to store images.
When I start reading about LOBs I see statements like "The system
administrator enables the database server for use by the Image Extender"
Does "server" mean that this can't be done in MVS? If NOT, then what is
meant by "the db2ext command-line processor"?
I will appreciate some help for a rookie.
Karl Sniderman
BlueCross BlueShield of Oklahoma








James Campbell

Re: Using LOBs
(in response to Kirk Hampton)
In this context, "server" means "a program that can respond to
requests for services". DB2 UDB has been able to meet that
criterion since DDF was introduced. Since DDF was enhanced to
support TCP/IP requests, it is as capable a server as any other.

DB2, for whatever platform, can store and retrieve BLOBS using
normal SQL. The "Image Extender" is an enhancement that
enables one to search for BLOBs based on the meaning of the
data inside the BLOB. Without it one just gets the BLOB data,
and you have to use other columns in the table for WHERE
predicates; Image Entender allows predicates based on the
contents of the BLOB. One can use BLOBs without it.

James Campbell


On 20 Dec 2001, at 17:30, [login to unmask email] wrote:

Date sent: Thu, 20 Dec 2001 17:30:56 -0600
Send reply to: DB2 Data Base Discussion List <[login to unmask email]>
From: [login to unmask email]
Subject: Re: [DB2-L] Using LOBs
To: [login to unmask email]

> Hi Karl,
> DB2 Version 6 on OS/390 is indeed called UDB, and does support
> LOB's, and I have seen references to "server" even though it is running on
> OS/390. But as far as I know, there is no db2ext command-line processor
> on OS/390, that would be on Unix/Windows/OS2.
>
> Kirk Hampton
> DB2 OS/390 Sysprog
> IBM Certified Solutions Expert - DB2 V7 Database Administration OS/390
> TXU Energy Services
> Dallas, Texas
>
>
>
>
>
> "Sniderman, Karl" <[login to unmask email]> on 12/20/2001 01:35:45 PM
>
> Please respond to DB2 Data Base Discussion List <[login to unmask email]>
>
> To: [login to unmask email]
> cc: (bcc: Kirk Hampton/BIZSRV/TXU)
> Subject: Using LOBs
>
>
>
> I need lots of help. First of all I am confused about UDB. We are running
> DB2 V6 on MVS (OS/390). Is this UDB?
> The reason I am confused is we may have a need for BLOB's to store images.
> When I start reading about LOBs I see statements like "The system
> administrator enables the database server for use by the Image Extender"
> Does "server" mean that this can't be done in MVS? If NOT, then what is
> meant by "the db2ext command-line processor"?
> I will appreciate some help for a rookie.
> Karl Sniderman
> BlueCross BlueShield of Oklahoma
>
>
>
>
>
>
>
> DB2-L webpage at htt
p://www.ryci.com/db2-l. The owners of the list can


James A Campbell