Re: How do I access Oracle from a korn shell script

From: Galen Boyer <galenboyer_at_yahoo.com>
Date: 27 Dec 2000 15:50:13 -0600
Message-ID: <usnn9h6zs.fsf_at_yahoo.com>


On Wed, 27 Dec 2000, orclnwsgrp_at_hotmail.com wrote:

> I'd like to issue a SQL select statement on a table in our
> database and somehow import the results back to my script for
> further processing.

#!/bin/ksh

sqlplus login/password_at_instance << EOF | awk OR sed OR grep > OutputFilename.txt

SELECT ....
;
EOF
> Is it necessary to invoke SQL+? Do I pipe the results of my
> select statement back to a file?

Yes, there is no way to access any database libraries from shell, but perl offers all sorts of ways. Maybe you can check that out.

-- 
Galen Boyer
Fingers and toes, fingers and toes, forty things we share.
Forty one if you include, the fact that we don't care.
Received on Wed Dec 27 2000 - 22:50:13 CET

Original text of this message