MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » May 2014

RE: Need to move all objects from lib A to lib B in batch mode with a replace option if the object already exists



fixed

Rob,

I've just completed a similar check with DSPOBJD of both libraries and a query.
I don't like using CRTDUPOBJ, you lose the original creator of the object and the create date.

Paul

-----Original Message-----
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of rob@xxxxxxxxx
Sent: Tuesday, May 06, 2014 9:36 AM
To: Midrange Systems Technical Discussion
Subject: RE: Need to move all objects from lib A to lib B in batch mode with a replace option if the object already exists

How comfortable are you with SQL? And creating UDFs? We've created a function called QCMDEXC.

So, with a output file of DSPOBJD of both libraries,

select a.odobnm, a.odlbnm, a.odobtp, qcmdexc('CRTDUPOBJ .... concat ... ) from aliboutput a left outer join bliboutput b...
where ....check dates, etc here...
order by 1 // the order by ensures the command performs all the QCMDEXC instead of stopping at the screen full




Rob Berendt





Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot COM and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available here. If you have questions about this, please contact