Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Unix question

Re: Unix question

From: Charlie Mengler <charliem_at_mwh.com>
Date: Fri, 23 Mar 2001 18:50:24 -0800
Message-ID: <F001.002D6F40.20010323184526@fatcity.com>

Yes & no.
There are a couple of different way to solve the problem. 1) Write your own functions/filters to accomplish the desired operations 2) If the only place in the file where double quote marks exists are around the hostname
    and all you want to do is get rid of them, the "tr" command could be used.
3) Unix scripts can accept command line arguments which are positionally dependant
so you could create a master script which would look like the following

driver.sh host1 schemaA
driver.sh host2 schemaB
driver.sh host9 schemaG
etc.......................

The inside driver.sh where you want the hostname to appear place a $1 The inside driver.sh where you want the schema    to appear place a $2
HTH & YMMV!
Big Planet wrote:

Hi
geeks ,How can I do substr
and instr kind of operaion in unix shell script . is it possible ?like i have one paramter as "hostname" .. I want to trim quotes surrounding the hostname .One more question
, is possible to read another text file line by line using a shel script
and then edit that file .Actually
I have this configuration file for my system which have keywords like $HOSTNAME$
, $SCHEMA$ which I want to replace with actual values at the time of installation
by asking questions to the user. TIA--Big planet   Received on Fri Mar 23 2001 - 20:50:24 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US