Jerry,
First do a db2 get db cfg for dbname. Look at the num_db_backup and rec_his_retentin parameters. These will limit the backup history. . To remove entries for all restores, loads, tablespace backups and full database backups taken before and including Feb 1, 2001 from the recovery history file enter:
 db2 prune history 200102

[EMAIL PROTECTED] wrote:

-------------- BEGIN db2eug.v002.n059 --------------

    001 - Jerry Long <Jerry.Long@ma - RE: Query on use of PRUNE HISTORY
    002 - "Amir Sadeghi" <amir_sade - Re: DB2EUG: INSERT with SELECT FIRST n ROWS ONLY
    003 - "McLeod, Scott" <Scott.Mc - DB2EUG: USEREXIT Sample
    004 - "John Lantz" <john.lantz@ - Re: DB2EUG: USEREXIT Sample
    005 - [EMAIL PROTECTED]       - Re: DB2EUG: USEREXIT Sample

===========================================
DB2EUG DIGEST
http://people.mn.mediaone.net/scottrmcleod/
For subscription info see bottom of message
===========================================

--------------- MESSAGE db2eug.v002.n059.1 ---------------

From: Jerry Long <[EMAIL PROTECTED]>
Subject: RE: Query on use of PRUNE HISTORY
Date: Mon, 9 Apr 2001 15:29:43 +1000
MIME-Version: 1.0
Content-Type: multipart/alternative;
        boundary="----_=_NextPart_001_01C0C0B6.14DB2160"

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C0C0B6.14DB2160
Content-Type: text/plain;
        charset="iso-8859-1"

> Hi,
>
> I'm a mainframer, new to DB2 on Solaris v6.1, and I'm establishing an infrastructure for our fledgling DB2/Solaris environment. Until now we have not been running the PRUNE HISTORY command, although we do have rec_his_retentn and num_db_backups set to reasonable limits.
>
> 'LIST HISTORY REORG ALL FOR db' gives reorg data going back further than my screen buffer can hold (probably several months), so I assume that rec_his_retentn and num_db_backups do not apply to reorg history data held in the recovery history file. As far as I can tell, 'PRUNE HISTORY yyyymmdd' also does not clear down reorg history data.
>
> Am I correct? Is there a way to clear down reorg history data? Does this data 'fall off the end' of the file like archlogs do in the BSDS in DB2/OS390? The manuals (which seem to omit more than they cover) appear to refer to administration of backup history only.
>
> Incidentally, can anyone explain when and where to use the terms 'DB2' and 'UDB'? Seems to me they are almost interchangeable.
>
> Thanks in anticipation for your assistance,
>
> Jerry Long
> MBL DBA
> [EMAIL PROTECTED]
>

------_=_NextPart_001_01C0C0B6.14DB2160
Content-Type: text/html;
        charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2651.75">
<TITLE>RE: Query on use of PRUNE HISTORY</TITLE>
</HEAD>
<BODY>
<UL>
<P><FONT SIZE=3D2 FACE=3D"Arial">Hi,</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">I'm a mainframer, new to DB2 on =
Solaris v6.1, and I'm establishing an infrastructure for our fledgling =
DB2/Solaris environment. Until now we have not been running the PRUNE =
HISTORY command, although we do have rec_his_retentn and num_db_backups =
set to reasonable limits. </FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">'LIST HISTORY REORG ALL FOR db' gives =
reorg data going back further than my screen buffer can hold (probably =
several months), so I assume that rec_his_retentn and num_db_backups do =
not apply to reorg history data held in the recovery history file. As =
far as I can tell, 'PRUNE HISTORY yyyymmdd' also does not clear down =
reorg history data.</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Am I correct? Is there a way to clear =
down reorg history data? Does this data 'fall off the end' of the file =
like archlogs do in the BSDS in DB2/OS390? The manuals (which seem to =
omit more than they cover) appear to refer to administration of backup =
history only.</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Incidentally, can anyone explain when =
and where to use the terms 'DB2' and 'UDB'? Seems to me they are almost =
interchangeable.</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Thanks in anticipation for your =
assistance,</FONT>
</P>

<P><FONT COLOR=3D"#000000" SIZE=3D2 FACE=3D"Arial">Jerry Long</FONT>
<BR><FONT COLOR=3D"#000000" SIZE=3D2 FACE=3D"Arial">MBL DBA</FONT>=20
<BR><FONT COLOR=3D"#000000" SIZE=3D2 =
FACE=3D"Arial">[EMAIL PROTECTED]</FONT>
</P>
</UL>
</BODY>
</HTML>
------_=_NextPart_001_01C0C0B6.14DB2160--

--------------- MESSAGE db2eug.v002.n059.2 ---------------

From: "Amir Sadeghi" <[EMAIL PROTECTED]>
Subject: Re: DB2EUG: INSERT with SELECT FIRST n ROWS ONLY
Date: Mon, 09 Apr 2001 16:28:26
MIME-Version: 1.0
Content-Type: text/plain; format=flowed

Christi,

I am not sure if 'WITH' before 'FETCH' is a valid syntax. I had never seen
it before and I just tried it. It gave me a syntax error.

Any ideas?

>From: "Christi Fortier " <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>To: [EMAIL PROTECTED]
>Subject: Re: DB2EUG: INSERT with SELECT FIRST n ROWS ONLY
>Date: Sat,  7 Apr 2001 09:29:29 -0400
>
>you need a "with" before the fetch.
>Good Luck!
>Christi Fortier,MSAS,Certified DB2 DBA, Sybase DBA
>DB Specialist(Admin/Architect/Performance/N-Tier/Web)
>PO Box 6012, Lawrenceville, NJ 08648-0012
>Phone: 609-912-0620
>e:  [EMAIL PROTECTED]
>Fax: pending
>URL: http://www.precise2spec.com/CRDB
>
>
>
>
>---------- Original Message ----------------------------------
>From: "Amir Sadeghi" <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>Date: Fri, 06 Apr 2001 23:20:40
>
>Hi Team,
>
>I would like to perform the following statement to insert some
>rows into a
>test table. DB2 is giving me a syntax error complaining
>about 'SQL0104N  An
>unexpected token "fetch" was found following "from"
>
>
>"insert into test select empl_num from incschem.employee fetch
>first 10 rows
>only"
>
>
>Does anyone know why this syntax is not allowed?
>___________________________________________________________________
>______
>Get Your Private, Free E-mail from MSN Hotmail at
>http://www.hotmail.com.
>
>
>=====
>To unsubscribe, send 'unsubscribe' to [EMAIL PROTECTED]
>For other info (and scripts), see
>http://people.mn.mediaone.net/scottrmcleod
>
>
>
>
>
>
>
>
>=====
>To unsubscribe, send 'unsubscribe' to [EMAIL PROTECTED]
>For other info (and scripts), see
>http://people.mn.mediaone.net/scottrmcleod
>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

--------------- MESSAGE db2eug.v002.n059.3 ---------------

From: "McLeod, Scott" <[EMAIL PROTECTED]>
Subject: DB2EUG: USEREXIT Sample
Date: Mon, 9 Apr 2001 13:20:15 -0500
MIME-Version: 1.0
Content-Type: text/plain

Does anyone have an NT based USEREXIT script to copy an archivelog file to a
new location they would be willing to share with me.  I know its not a very
complicated script and I've written them in the past for AIX but if someone
already has one and can keep from reinventing the wheel the would be great.

> TTFN and Hold Fast!
> Scott McLeod of MacLeod
> Best Buy, Inc.
> Sr. Database Architect
> 7750 Flying Cloud Dr.
> Eden Prairie, MN 55344
>
> (612) 324-0031 (voice)
> (612) 324-0828 (fax)
>
> [EMAIL PROTECTED]
>
>

--------------- MESSAGE db2eug.v002.n059.4 ---------------

From: "John Lantz" <[EMAIL PROTECTED]>
Subject: Re: DB2EUG: USEREXIT Sample
Date: Mon, 9 Apr 2001 15:37:47 -0400
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

At one time, we had taken the sample C++ code that is provided under
samples (I believe it's called db2uext2.cdisk).  There were only a few
things to change and then we compiled it.  It worked, but we had
intermittent problems where some log files were not copied.   The log files
would be left sitting on the active log directory.  Since we really didn't
know C++ that much and we couldn't figure out a way to debug it, we
abandoned it.

So we wrote a couple of REXX scripts that manage the log files.  Everyday,
we kick off a script that will copy the log files over to an archive
directory based on the "first active log file" that you get when you do a
"get db cfg for database ...".   It's not quite as good as a user exit
getting called every time a new log is created, but it serves our purpose
of getting rid of old log files and making copies that could be used in the
event of a disaster.

John Lantz
Zurich North America

"McLeod, Scott" <[EMAIL PROTECTED]>@lists1.ba.best.com on 04/09/2001
02:20:15 PM

Please respond to [EMAIL PROTECTED]

Sent by:  [EMAIL PROTECTED]

To:   [EMAIL PROTECTED]
cc:

Subject:  DB2EUG: USEREXIT Sample

Does anyone have an NT based USEREXIT script to copy an archivelog file to
a
new location they would be willing to share with me.  I know its not a very
complicated script and I've written them in the past for AIX but if someone
already has one and can keep from reinventing the wheel the would be great.

> TTFN and Hold Fast!
> Scott McLeod of MacLeod
> Best Buy, Inc.
> Sr. Database Architect
> 7750 Flying Cloud Dr.
> Eden Prairie, MN 55344
>
> (612) 324-0031 (voice)
> (612) 324-0828 (fax)
>
> [EMAIL PROTECTED]
>
>

=====
To unsubscribe, send 'unsubscribe' to [EMAIL PROTECTED]
For other info (and scripts), see
http://people.mn.mediaone.net/scottrmcleod

--------------- MESSAGE db2eug.v002.n059.5 ---------------

From: [EMAIL PROTECTED]
Subject: Re: DB2EUG: USEREXIT Sample
Date: Mon, 9 Apr 2001 15:58:34 -0400
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

Scott
check in the sqllib\samples\c directory for db2uext2.cdisk
Regards,

_____________________________________________
Dale M. McInnis             IBM Toronto Lab
Senior Technical Manager, DB2 UDB Backup,  Data Protection and Recovery
Email: [EMAIL PROTECTED]
Phone: (416) 448-2397,  Fax: (416) 448-4414, T/L: 778-2397

|--------+-------------------------------->
|        |          "McLeod, Scott"       |
|        |          <Scott.McLeod@bestbuy.|
|        |          com>                  |
|        |          Sent by:              |
|        |          [EMAIL PROTECTED]|
|        |          a.best.com            |
|        |                                |
|        |                                |
|        |          04/09/2001 02:20 PM   |
|        |          Please respond to     |
|        |          db2eug                |
|        |                                |
|--------+-------------------------------->
  >-----------------------------------------------------------------------------------------------------------|
  |                                                                                                           |
  |      To:     [EMAIL PROTECTED]                                                                    |
  |      cc:                                                                                                  |
  |      Subject:     DB2EUG: USEREXIT Sample                                                                 |
  |                                                                                                           |
  |                                                                                                           |
  >-----------------------------------------------------------------------------------------------------------|

Does anyone have an NT based USEREXIT script to copy an archivelog file to
a
new location they would be willing to share with me.  I know its not a very
complicated script and I've written them in the past for AIX but if someone
already has one and can keep from reinventing the wheel the would be great.

> TTFN and Hold Fast!
> Scott McLeod of MacLeod
> Best Buy, Inc.
> Sr. Database Architect
> 7750 Flying Cloud Dr.
> Eden Prairie, MN 55344
>
> (612) 324-0031 (voice)
> (612) 324-0828 (fax)
>
> [EMAIL PROTECTED]
>
>

=====
To unsubscribe, send 'unsubscribe' to [EMAIL PROTECTED]
For other info (and scripts), see
http://people.mn.mediaone.net/scottrmcleod

--------------- END db2eug.v002.n059 ---------------

=====
You are subscribed to the DB2EUG digest. To receive messages
separately, send email to [EMAIL PROTECTED]
containing the line: subsingle <your-email-address>
To unsubscribe, send: unsubscribe <your-email-address>

===== To unsubscribe, send 'unsubscribe' to [EMAIL PROTECTED] For other info (and scripts), see http://people.mn.mediaone.net/scottrmcleod

Reply via email to