Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
output of a cmd>replace a line
Name: arun.s Date: November 16, 2005 at 05:02:24 Pacific OS: unix CPU/Ram: 255
Comment:
Hi,
i have a script which will generate som encrypted pwd and i need to replace this pwd to the existing one in a file.
generatencrypt=arundatabase will generate password as 3490327483274893789
and my sample file is sample.ksh DBPASS=90904373739049 DBUID=testdatabase
i need to replace DBPASS=90904373739049 by newly generated password.. i tried the following command. but its not working properly. the command i used is generatencrypt=arundatabase|sed "s/^DBPASS=[0-9]*$/DBPASS= /g" sample.ksh
if i can place that newly generated encrypted password in place of */DBPASS=?????/g' (here) problem is solved...
i m looking after for someones help.. send me the solution as soon as possible
Name: koala95 Date: November 16, 2005 at 07:10:26 Pacific
Reply:
I can't understand that generatencrypt=arundatabase. I guess u want to generate a password by pass a parameter(arundatabase) to generatencrypt. if as I think that. you can do like a previous reply #/bin/ksh passwd=`generatencrypt arundatabase` sed "s/DBPASS.*/DBPASS=$passwd/" sample.ksh
Summary: I want to redirect the output of a PL/SQL procedure to a log file. In this file I want to have all the output of the execution, the results of every step, errors, etc.. I have tried with a UNIX pipe (...
Summary: Hi all, I'm wondering if there is an easier way to processing the output of a process then the way I'm doing. Currently, for example, I do a nawk/grep on a file and it outputs results, I want to run ...
Summary: Hi, Is there any possible way to save the results of a sed command to the same file I'm working on? For example, I have a command: sed -f sedcmd myFile and I want to save the results to myFile. I don'...