×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
for the insert you *should* be able to do something along the lines of
mystatement = 'INSERT INTO MYLIB/MYFILE (SELECT A.*, ''' + MYFILENAME +
''' FROM ' + %TRIM(MYNEWLIB) + '/' %TRIM(MYNEWFILE) + ' A UNION ALL SELECT
B.*, ''' +
MYOTHERFILENAME + ''' FROM ' + %TRIM(MYOTHERLIB) + '/' +
%TRIM(MYOTHERFILE) + ' B )';
exec sql execute immediate :mystatement;
Thanks,
Tommy Holden
From: "Dennis Lovelady" <iseries@xxxxxxxxxxxx>
To: "'Midrange Systems Technical Discussion'"
<midrange-l@xxxxxxxxxxxx>
Date: 03/16/2010 08:51 AM
Subject: RE: Select mytable name from mytable?
Sent by: midrange-l-bounces@xxxxxxxxxxxx
what exactly would make it fail on the first rename when you are
building
the INSERT on the fly? here is a sample program i wrote years ago that
does this type of thing and haven't had a problem ever...
Nothing at all (I'll look at the program later; thanks). But since data
tends to persist in files, whatever data was in there before the rename is
now misrepresenting the file in which it resides. That is unless you also
update all data when you rename. But there's no system constraint to
ensure
that you'll do that, is there?
Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"I wasn't kissing her, I was whispering in her mouth."
-- Chico Marx
As an Amazon Associate we earn from qualifying purchases.