473,796 Members | 2,525 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Unloading LOBs on DB2 v7.1 on OS/390

Hi.

Once a LOB size goes beyond 32KB in size, I'm not able to use the LOAD
utility to unload the data off the tables for DB2 7.1 on OS/390.
Instead, the documentation refers to a sample C++ program --
DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

I'm wondering if anyone out there has a COBOL equivalent to this as I do
not have a C++ compiler?

Would I be able to use the same program to load LOBs larger than 32KB?

Lastly, how do you generally manage LOBs that are greater than 32KB in size?

Any response appreciated.

Thanks and best regards.

Rom Marshall
Nov 12 '05 #1
9 4428
We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third party
software says it will support it (BMC has a V2 product as part of it's
DB2 Admin Solution Set - I forget the name but they just did a webex on it
- supports up to 32 MB). I think the real issue in the program is the
OS file record size limits. Hard to get over 32K, so you have to take it
apart and put it together.
RM> Hi.

RM> Once a LOB size goes beyond 32KB in size, I'm not able to use the LOAD
RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
RM> Instead, the documentation refers to a sample C++ program --
RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

RM> I'm wondering if anyone out there has a COBOL equivalent to this as I do
RM> not have a C++ compiler?

RM> Would I be able to use the same program to load LOBs larger than 32KB?

RM> Lastly, how do you generally manage LOBs that are greater than 32KB in size?

RM> Any response appreciated.

RM> Thanks and best regards.

RM> Rom Marshall

Edward Lipson via Relaynet.org Moondog
ed***********@m oondog.com el*****@bankofn y.com
---
þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!
Nov 12 '05 #2
If your text is limited to 32K, you'd be better off using VARCHAR on a
32K page.

EDWARD LIPSON wrote:
We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third party
software says it will support it (BMC has a V2 product as part of it's
DB2 Admin Solution Set - I forget the name but they just did a webex on it
- supports up to 32 MB). I think the real issue in the program is the
OS file record size limits. Hard to get over 32K, so you have to take it
apart and put it together.
RM> Hi.

RM> Once a LOB size goes beyond 32KB in size, I'm not able to use the LOAD
RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
RM> Instead, the documentation refers to a sample C++ program --
RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

RM> I'm wondering if anyone out there has a COBOL equivalent to this as I do
RM> not have a C++ compiler?

RM> Would I be able to use the same program to load LOBs larger than 32KB?

RM> Lastly, how do you generally manage LOBs that are greater than 32KB in size?

RM> Any response appreciated.

RM> Thanks and best regards.

RM> Rom Marshall

Edward Lipson via Relaynet.org Moondog
ed***********@m oondog.com el*****@bankofn y.com
---
þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!


Nov 12 '05 #3
> I think the real issue in the program is the
OS file record size limits. Hard to get over 32K, so you have to take it
apart and put it together.


I've done RECFM=U cobol file processing in the past so 32k is not
allways the limit for logical records.

I think that the 32k limit is because the cobol BL and BLL cells can
(could?) only point/reference
adresses in the 32k following the base address. /offset

Logically, LOBS are 1 record.

PM
Nov 12 '05 #4
Unfortunately, the application I am using -- WBIFN -- has defined the
BLOBs to be 100MB in size. But they have not provided any mechanism for
backing up/restoring the data. Instead, the manual says to refer to the
DB2 manuals for the appropriate mechanism. Hah!

I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to back
it up. But then, the world's full of puzzles ...

One suggestion I got was to use the DSN1COPY facility. But this raises
the possibility that I may not be able to restore the data when I move
my DB2 to a different version eventually.

Hence the search for an unloading/loading mechanism.

Rom Marshall

Blair Adamache wrote:
If your text is limited to 32K, you'd be better off using VARCHAR on a
32K page.

EDWARD LIPSON wrote:
We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third party
software says it will support it (BMC has a V2 product as part of it's
DB2 Admin Solution Set - I forget the name but they just did a webex
on it - supports up to 32 MB). I think the real issue in the program
is the OS file record size limits. Hard to get over 32K, so you have
to take it apart and put it together.
RM> Hi.

RM> Once a LOB size goes beyond 32KB in size, I'm not able to use the LOAD
RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
RM> Instead, the documentation refers to a sample C++ program --
RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

RM> I'm wondering if anyone out there has a COBOL equivalent to this as I do
RM> not have a C++ compiler?

RM> Would I be able to use the same program to load LOBs larger than 32KB?

RM> Lastly, how do you generally manage LOBs that are greater than 32KB in size?

RM> Any response appreciated.

RM> Thanks and best regards.

RM> Rom Marshall

Edward Lipson via Relaynet.org Moondog
ed***********@m oondog.com el*****@bankofn y.com
---
þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!


Nov 12 '05 #5
Can you cast them to varchar(31K) when unloading:

db2 select varchar(col1,31 000) from testclob

Rom Marshall wrote:
Unfortunately, the application I am using -- WBIFN -- has defined the
BLOBs to be 100MB in size. But they have not provided any mechanism for
backing up/restoring the data. Instead, the manual says to refer to the
DB2 manuals for the appropriate mechanism. Hah!

I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to back
it up. But then, the world's full of puzzles ...

One suggestion I got was to use the DSN1COPY facility. But this raises
the possibility that I may not be able to restore the data when I move
my DB2 to a different version eventually.

Hence the search for an unloading/loading mechanism.

Rom Marshall

Blair Adamache wrote:
If your text is limited to 32K, you'd be better off using VARCHAR on a
32K page.

EDWARD LIPSON wrote:
We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third
party software says it will support it (BMC has a V2 product as part
of it's DB2 Admin Solution Set - I forget the name but they just did
a webex on it - supports up to 32 MB). I think the real issue in the
program is the OS file record size limits. Hard to get over 32K, so
you have to take it apart and put it together.
RM> Hi.

RM> Once a LOB size goes beyond 32KB in size, I'm not able to use the
LOAD
RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
RM> Instead, the documentation refers to a sample C++ program --
RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

RM> I'm wondering if anyone out there has a COBOL equivalent to this
as I do
RM> not have a C++ compiler?

RM> Would I be able to use the same program to load LOBs larger than
32KB?

RM> Lastly, how do you generally manage LOBs that are greater than
32KB in size?

RM> Any response appreciated.

RM> Thanks and best regards.

RM> Rom Marshall

Edward Lipson via Relaynet.org Moondog
ed***********@m oondog.com el*****@bankofn y.com
---
þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!



Nov 12 '05 #6
Most of the BLOBs are <32K but there are those that are larger in size.
I would end up unloading truncated data by doing that.

Blair Adamache wrote:
Can you cast them to varchar(31K) when unloading:

db2 select varchar(col1,31 000) from testclob

Rom Marshall wrote:
Unfortunately, the application I am using -- WBIFN -- has defined the
BLOBs to be 100MB in size. But they have not provided any mechanism
for backing up/restoring the data. Instead, the manual says to refer
to the DB2 manuals for the appropriate mechanism. Hah!

I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to
back it up. But then, the world's full of puzzles ...

One suggestion I got was to use the DSN1COPY facility. But this
raises the possibility that I may not be able to restore the data when
I move my DB2 to a different version eventually.

Hence the search for an unloading/loading mechanism.

Rom Marshall

Blair Adamache wrote:
If your text is limited to 32K, you'd be better off using VARCHAR on
a 32K page.

EDWARD LIPSON wrote:

We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third
party software says it will support it (BMC has a V2 product as part
of it's DB2 Admin Solution Set - I forget the name but they just did
a webex on it - supports up to 32 MB). I think the real issue in the
program is the OS file record size limits. Hard to get over 32K, so
you have to take it apart and put it together.
RM> Hi.

RM> Once a LOB size goes beyond 32KB in size, I'm not able to use
the LOAD
RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
RM> Instead, the documentation refers to a sample C++ program --
RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.

RM> I'm wondering if anyone out there has a COBOL equivalent to this
as I do
RM> not have a C++ compiler?

RM> Would I be able to use the same program to load LOBs larger than
32KB?

RM> Lastly, how do you generally manage LOBs that are greater than
32KB in size?

RM> Any response appreciated.

RM> Thanks and best regards.

RM> Rom Marshall

Edward Lipson via Relaynet.org Moondog
ed***********@m oondog.com el*****@bankofn y.com
---
þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!

Nov 12 '05 #7
> I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to back
it up. But then, the world's full of puzzles ...

Rom
you can use DB2 COPY utility to back up your LOB table spaces,
and RECOVER to recover them.
Note that you must COPY the table space set in
SHRLEVEL REFERENCE when the LOB table space is defined without
logging, and that you must recover the entire table space set
in case you do a point-in-time recovery.

Instead of unloading, you may consider to copy the LOB data
to a clone of the table using SQL INSERT INTO ... SELECT FROM.
This works also for large LOBs. This way you can at least put
your LOB data somewhere safe if you have to drop the
table spaces for some reason. When you use LOBs in DB2, you will
most probably run into data corruption problems, the DB2 software
still is very wobbly in this area. The SQL method will allow to
at least pick out those rows that are still readable and put them
into a new table space.

regards,
Heinz Buehler
Nov 12 '05 #8
Heinz, hi.

You've given me some ideas for short term data protection -- thanks for
that thought.

I looked back and realised that I didn't explain why I seemed bent on
using LOAD. The biggest reason is that we may need to recover the data
up to 7 years from now -- the local (Singaporean) monetary authority
requires us to keep customer information for a period that long.

If, for some reason, we have to restore 6 year old data, we would
probably face a problem if there are data file incompatibiliti es between
the version of DB2 at the time we took the COPY and the version at the
time we attempt to do a RECOVER.

A DSN1COPY is just as problematic for the same reason.

LOAD bypasses this problem by extracting out the data.

On the open platforms (AIX, Windows, etc), one other way around would be
to use EXPORT in IXF format. This does not exist on the OS/390
environment, unfortunately.

I have one idea lurking at the back of my mind, and that's to catalog
the database on the OS/390 to an AIX/Windows box and perform a backup
from there. I don't know if this would work, though, as I have not
tried such a thing yet. Does anyone know? And, if I do this, will I
lose any data -- e.g. authentication or privilege settings?

Rom Marshall

Heinz Buehler wrote:
I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to back
it up. But then, the world's full of puzzles ...


Rom
you can use DB2 COPY utility to back up your LOB table spaces,
and RECOVER to recover them.
Note that you must COPY the table space set in
SHRLEVEL REFERENCE when the LOB table space is defined without
logging, and that you must recover the entire table space set
in case you do a point-in-time recovery.

Instead of unloading, you may consider to copy the LOB data
to a clone of the table using SQL INSERT INTO ... SELECT FROM.
This works also for large LOBs. This way you can at least put
your LOB data somewhere safe if you have to drop the
table spaces for some reason. When you use LOBs in DB2, you will
most probably run into data corruption problems, the DB2 software
still is very wobbly in this area. The SQL method will allow to
at least pick out those rows that are still readable and put them
into a new table space.

regards,
Heinz Buehler

Nov 12 '05 #9
Partial answer - could you get the short ones using the length function:

select varchar(col1,31 000) from testclob where length(col1)<32 728

Rom Marshall wrote:
Most of the BLOBs are <32K but there are those that are larger in size.
I would end up unloading truncated data by doing that.

Blair Adamache wrote:
Can you cast them to varchar(31K) when unloading:

db2 select varchar(col1,31 000) from testclob

Rom Marshall wrote:
Unfortunately, the application I am using -- WBIFN -- has defined the
BLOBs to be 100MB in size. But they have not provided any mechanism
for backing up/restoring the data. Instead, the manual says to refer
to the DB2 manuals for the appropriate mechanism. Hah!

I'm finding it more than a little puzzling that DB2 provides the
facility to create such large LOBs but do not provide a utility to
back it up. But then, the world's full of puzzles ...

One suggestion I got was to use the DSN1COPY facility. But this
raises the possibility that I may not be able to restore the data
when I move my DB2 to a different version eventually.

Hence the search for an unloading/loading mechanism.

Rom Marshall

Blair Adamache wrote:

If your text is limited to 32K, you'd be better off using VARCHAR on
a 32K page.

EDWARD LIPSON wrote:

> We are DB2 6 and 7. We limit CLOBs to 31K because of this. Third
> party software says it will support it (BMC has a V2 product as
> part of it's DB2 Admin Solution Set - I forget the name but they
> just did a webex on it - supports up to 32 MB). I think the real
> issue in the program is the OS file record size limits. Hard to get
> over 32K, so you have to take it apart and put it together.
>
>
> RM> Hi.
>
> RM> Once a LOB size goes beyond 32KB in size, I'm not able to use
> the LOAD
> RM> utility to unload the data off the tables for DB2 7.1 on OS/390.
> RM> Instead, the documentation refers to a sample C++ program --
> RM> DSN710.SDSNSAMP (DSN8DLPL) to use for this purpose.
>
> RM> I'm wondering if anyone out there has a COBOL equivalent to
> this as I do
> RM> not have a C++ compiler?
>
> RM> Would I be able to use the same program to load LOBs larger
> than 32KB?
>
> RM> Lastly, how do you generally manage LOBs that are greater than
> 32KB in size?
>
> RM> Any response appreciated.
>
> RM> Thanks and best regards.
>
> RM> Rom Marshall
>
> Edward Lipson via Relaynet.org Moondog
> ed***********@m oondog.com el*****@bankofn y.com
> ---
> þ MM 1.1 #0361 þ MONEY TALKS ... all mine ever says is GOODBYE!



Nov 12 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2019
by: Fredrik Lindstrom | last post by:
Hi folks! When I browse the web about information regarding dequeue and enqueue (b)lobs to an Advanced Queue in PRO/C I do not find a good example. About RAW I can find a lot of info and because I am new to Oracle I just do not know if it is any difference between LOB and RAW in this case (it surely would, or?). Does anyone know a good an well explained example about this so that I can understand what I am doing? Right now I am...
1
1634
by: LilleSkutt | last post by:
I want to use assemblies (Window Forms as .dll) so that I can replace the form while the main application is running. To accomplish this, I used Assembly.LoadForm to manually load the assembly when I need it from a .DLL file. I then use CreateInstance to create the instance of the class, and then use the instance like I would use is with a normal design-time included assembly. But the problem is, no matter how I try with closing the form,...
1
2566
by: stoat2337 | last post by:
I'm looking to purge rows from a DB2 table that contains both a CLOB (1M) and BLOB (51K), but our DBA is not familiar with LOBs. I work on a mainframe (z/OS), and we don't normally use LOBs in our shop. These LOBs were set up by a vendor. Our DBA mentioned that a simple DELETE would not work, but he thought that a COBOL program could be written to do the job. Any ideas?
2
7013
by: mjf | last post by:
Hello, I have a table that has a BLOB field, which is defined as follows: create table raw_image( image_id INTEGER NOT NULL, image BLOB(2M)) I intend to use import utility to import bunch of pictures (images) into the above table, but I cannot find an example on how to setup a lobsinfile. I think the import statement will be: ------
4
1912
by: Stanley Sinclair | last post by:
Given I have binary input which is to be stored in one table, and it may consist of any size -- ie, VARCHAR(n) FOR BIT DATA, WHERE THE n is less than 32K, or the n is bigger such that it is a BLOB ... Given that I have a LOB table too, named LOBTABLE, Is there any problem with, CREATE TABLE( ID INTEGER NOT NULL,
2
1606
by: Guru Prasad | last post by:
Is there a delay involved in unloading assemblies once a virtual directory is "deleted" using IIS Manager ? At times even after the virtual directory is removed i cannot delete the backing physical directory and it looks like ASPNET runtime is holding on to the assemblies. Once i recycle the ASPNET process, i can delete this directory. Has this got anything to do with strong-named/signed assemblies ( even though deployed as private...
0
1569
by: ibenc | last post by:
Is there a way to prevent w3wp.exe from unloading a particular appDomain. Some parameters, config files? Here is some info about why I need this. I have a long running background thread in asp.Net application. Occasionaly, especially during peek CPU usage, the appDomain of the application gets unloaded by the w3wp.exe, and the background thread is terminated (we receive thread was being aborted exception). I guess the reason for...
1
2666
by: gezerpunta | last post by:
Hi I need to fetch lobs with php script. I found it but there is an error. $stmt = $db->prepare("select * from test where oid = 17056"); $stmt->execute(); $stmt->bindColumn('oid', $lob, PDO::PARAM_LOB); $stmt->fetch(PDO::FETCH_BOUND); echo $lob;
0
1305
vdraceil
by: vdraceil | last post by:
Hi,i use VB6.0..is it possible to prevent a form from unloading ever? I know to set cancel=true in query unload event of the form..but this applies only to limited cases. If my exe is closed from the task manager-"Applications" tab,i can detect it and prevent it from unloading,but if it is closed from the task manager-"Processes" tab,the form will be closed even without passing through the terminate,queryunload and unload events... I'm...
0
9679
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10453
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10003
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9050
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5441
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5573
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4115
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3730
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2924
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.