|
On Jan 6, 2015, at 5:31 PM, Evan Harris <auctionitis@xxxxxxxxx> wrote:
If I wanted to put the output on the i I think I would consider using the
qshell db2 command as opposed to running an odbc script on a pc and mapping
the output back to the i via a share.
Much better to run the query on the i if the output will end up there (in
my opinion anyway)
That said, there's a lot to be said for Python or Java vs Qshell scripts...
On Wed, Jan 7, 2015 at 11:24 AM, Buck Calabro <kc2hiz@xxxxxxxxx> wrote:
On 1/6/2015 5:03 PM, Darryl Freinkel wrote:
Let me add some clarity.
I am using v5r4 and am using the iNavigator's "Run a sql script".
So all is native in iNav.
I would like to continue running the scripts from iNav.
I would like something like
Runsql script1
Runsql script2
Runsql script3
The iNav for Windows script program is called CWBUNDBS. You should
think of it as an interactive program. There is no 'batch' mode.
If I had to do this, I'd write a Python or Java program that would read
those scripts and then submit them to IBM i via ODBC / JDBC. Map a
windows drive to your IFS (that's where I keep mine). That way you
could still maintain them interactively via iNav, and run them via a
.bat file as needed.
I know you said that you run them from the PC, but for the archives, one
could also run the same scripts on IBM i through a similar mechanism
(read the stream file in RPG / Java / Python and submit via ODBC).
fileOn Jan 5, 2015, at 8:54 AM, rob@xxxxxxxxx wrote:
I understand that you want to run these scripts on your PC. So I think
you're looking for something like the commands IBM supplies for batch
Theytransfer but instead supports your PC based SQL scripts.
Most others are suggesting running commands on the IBM i to run SQL.
positivemight not understand what you are asking. But to put them into a
thelight, running the SQL on the IBM i might perform better by doing all
directlysummarizing on the big iron and just passing the results back to the PC.
Failing that, and a continuation on attempting to run SQL scripts
Ion your PC I know there is a way. We actually did this from DOS before
outdiscovered the old freebie RUNSQL (which was supplanted by IBM coming
how...with their own a decade or so later). Now if I could only remember
typeGot a lot of work to catch up...
Maybe the ODBC connectivity stuff?
Maybe putting the SQL into excel?
Maybe just running the file transfers and then accessing the downloaded
data?
Rob Berendt
From: "Darryl Freinkel" <dfreinkel@xxxxxxxxxxxxxxxxx>
To: <midrange-l@xxxxxxxxxxxx>
Date: 01/01/2015 05:34 PM
Subject: is there a way too batch SQL scripts
Sent by: "MIDRANGE-L" <midrange-l-bounces@xxxxxxxxxxxx>
I have about 10 separate SQL scripts that I run from the PC command line
using the iNavigator SQL interface.
What I need to do is something like call each script in a batch(BAT)
CLfile.
Has anyone done this before?
I do not want to run these using a series of runsqlstm statements in a
filesprogram. Using RUNSQLSTM needs me to convert the scripts into source
multiple
and the width of the source file requires me to break lines into
lines which gets very messay.
Darryl Freinkel
--
--buck
'I had nothing to offer anybody except my own confusion' - Jack Kerouac
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
--
Regards
Evan Harris
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.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 on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.