Search Results

Search: Posts Made By: sudheer1984
8,360
Posted By sudheer1984
For me it worked when i use 4 '\' in side script ...
For me it worked when i use 4 '\' in side script


VAR=$(echo $ENVDB | sed 's/\\\\/\\\\\\\\/')
8,360
Posted By sudheer1984
Its working from command line, But when i run it...
Its working from command line, But when i run it from a script not working


$ cat file
one,ABCD\XYZ,Server One
$ cat run
#!/usr/bin/ksh
ENVDB='ABCD\XYZ'
VAR=`echo $ENVDB | sed 's/\\/\\\\/'`...
8,360
Posted By sudheer1984
But, i need to get the value into VAR from...
But, i need to get the value into VAR from another var ENVDB


$ echo $ENVDB
ABCD\XYZ
$ VAR=`echo "$ENVDB" | sed "s/\\/\\\\/"`
sed: command garbled: s/\/\/



Any idea, how to put the...
8,360
Posted By sudheer1984
No, Its not working.. $:~% cat file ...
No, Its not working..


$:~% cat file
one,ABCD\XYZ,Server One

$:~% cat run
#!/usr/bin/ksh
VAR="ABCD\XYZ"
sed "s/$VAR/SERVER/" file

$:~% run
one,ABCD\XYZ,Server One
$:~%


...
8,360
Posted By sudheer1984
Sorry, But i dont want to hard code ABCD/XYZ. it...
Sorry, But i dont want to hard code ABCD/XYZ. it should be in a variable.


VAR=ABCD\XYZ
sed 's/$VAR/SERVER/'


when i use a variable its not replacing.. in ksh
8,360
Posted By sudheer1984
sed problem in ksh
Hi,

I have the following issue while replacing text in a file usind sed


$ cat file
$ One,ABCD\XYZ,Server one


i want to replace ABCD\XYZ with another text SERVER. with ABCD\XYZ stored...
3,845
Posted By sudheer1984
Thanks for that.
Thanks for that.
3,845
Posted By sudheer1984
Thanks gaurav. Thats equally useful. ...
Thanks gaurav. Thats equally useful.

Sudheer.
3,845
Posted By sudheer1984
Hi Franklin, Excellent. Superb solution....
Hi Franklin,

Excellent. Superb solution. Really doing some magic. though still i did not understand how is it working, but its working.

Thanks for that.

can i get some document to...
3,845
Posted By sudheer1984
Hi ni2 two issues with this, 1. the...
Hi ni2

two issues with this,

1. the number of line to delete above the text ERROR:0000 may not always be 2 (same).
2.I have to run this on a Unix based machine, grep on our server does not...
3,845
Posted By sudheer1984
delete rows between closest pattern or range
Hi

I am having some problom deleting the lines between two specific lines in a file. need to delete lines between two closest lines. i.e need to find the closest range or pattern in a file with...
4,519
Posted By sudheer1984
guys, any suggestions?
guys,
any suggestions?
4,519
Posted By sudheer1984
capture sqsh segmentation fault error
hi all

is there any way to capture the segmentation fault error when i run sqsh on a unix shell script.

Ex:


#!/bin/ksh
sqsh -S "server" -U "user" -P "pwd" << EOF
use mydb
go
exec...
5,108
Posted By sudheer1984
sed match closest/nearest pattern
All
i am struggling to raplace some text in a line between two (closest) patterns ,
line="/home/usr/bin/:/home/usr/devuser,n1.9/bin:/home/usr/root/bin"
i want to replace "devuser,n1.9" with...
Showing results 1 to 14 of 14

 
All times are GMT -4. The time now is 02:41 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy