09-08-2015
What sed command did you try?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I need a script for...
how to find a position of column data and print some string in the next line and same position
position should find based on *HEADER8* in text
for ex: ord123 abs 123 987HEADER89 test234
ord124 abc 124 987HEADER88 test235
... (1 Reply)
Discussion started by: naveenkcl
1 Replies
2. Shell Programming and Scripting
Hi All,
My requisite is to search for the string "0108"(which is the year and has come in the wrong year format) in a particular column say 4th column in a tab delimited file and then replace it with 2008(the correct year format) in the same position where 0108 was found..The issue is the last... (15 Replies)
Discussion started by: ganesh_248
15 Replies
3. UNIX for Dummies Questions & Answers
Hi All,
My requisite is to search for the string "0108"(which is the year and has come in the wrong year format) in a particular column say 4th column in a tab delimited file and then replace it with 2008(the correct year format) in the same position where 0108 was found in the same file..The... (27 Replies)
Discussion started by: ganesh_248
27 Replies
4. Shell Programming and Scripting
Suppose i have a file which contains thousands of records. e.g adjgmptjadmwpgjmwmd i need to replace the string from 3rd to 8th position using awk script in entire file. And also the positions will be passed as parameter. (3 Replies)
Discussion started by: laknar
3 Replies
5. UNIX for Dummies Questions & Answers
Trying to use sed - but having no luck.
I have a text file - I want to replace whatever character is in position 106, 157 and 237 w/ the string "xxx". Want this change for all lines w/in that text file.
I'm open to using awk or whatever command would be best for replacing characters based... (5 Replies)
Discussion started by: svn
5 Replies
6. UNIX for Dummies Questions & Answers
Hi
I am looking for a particular string in a file.If the string exists, then I want to replace another string with some other text.Once replaced, search for the same text after that character position in the file. :wall:
E.g: Actual File content:
Hello
Name: Nitin Raj
Welcome to Unix... (4 Replies)
Discussion started by: dashing201
4 Replies
7. Shell Programming and Scripting
Hi All,
I have a file that I would like to search for data and replace other data by record position number:
Example search..
search for "CLARK KENT" and replace Amt data "000025" with "000155"???
I'm able to search and replace unique data but, came to a stump when wanting to replace data... (11 Replies)
Discussion started by: macastor
11 Replies
8. Shell Programming and Scripting
here is what i want to achieve... consider a file contains below contents. the file size is large about 60mb
cat dump.sql
INSERT INTO `table1` (`id`, `action`, `date`, `descrip`, `lastModified`) VALUES (1,'Change','2011-05-05 00:00:00','Account Updated','2012-02-10... (10 Replies)
Discussion started by: vivek d r
10 Replies
9. Shell Programming and Scripting
Hi,
I am unable to find the right option to extract the data in the fixed width file.
sample data
abcd1234xgyhsyshijfkfk
hujk9876 io xgla
loki8787eljuwoejroiweo
dkfj9098 dja
Search based on position 8-9="xg" and print the entire row
output
... (4 Replies)
Discussion started by: onesuri
4 Replies
10. Shell Programming and Scripting
Sample txt file :
OK00001111112|
OK00003443434|skjdaskldj
OK32812983918|asidisoado
OK00000000001|
ZM02910291029|sldkjaslkjdasldjk
what would be the shell script to figure out the blank space (if any) after the pipe sign? (4 Replies)
Discussion started by: chatwithsaurav
4 Replies
LEARN ABOUT REDHAT
nwbpset
NWBPSET(1) nwbpset NWBPSET(1)
NAME
nwbpset - Create a bindery property or set its value
SYNOPSIS
nwbpset [ -h ] [ -S server ] [ -U user name ] [ -P password | -n ] [ -C ]
DESCRIPTION
nwbpset Reads a property specification from the standard input and creates and sets the corresponding property. The format is determined by
the output of 'nwbpvalues -c'. nwbpset will hopefully become an important part of the bindery management suite of ncpfs, together with
As another example, look at the following command line:
nwbpvalues -t 1 -o supervisor -p user_defaults -c |
sed '2s/.*/ME/'|
sed '3s/.*/LOGIN_CONTROL/'|
nwbpset
With this command, the property user_defaults of the user object 'supervisor' is copied into the property login_control of the user object
'me'.
nwbpvalues -t 1 -o me -p login_control -c |
sed '9s/.*/ff/'|
nwbpset
This command disables the user object me.
Feel free to contribute other examples!
nwbpset looks up the file $HOME/.nwclient to find a file server, a user name and possibly a password. See nwclient(5) for more information.
Please note that the access permissions of $HOME/.nwclient MUST be 600 for security reasons.
OPTIONS
-h
-h is used to print out a short help text.
-S server
server is the name of the server you want to use.
-U user
user is the user name to use for login.
-P password
password is the password to use for login. If neither -n nor -P are given, and the user has no open connection to the server, nwbpset
prompts for a password.
-n
-n should be given if no password is required for the login.
-C
By default, passwords are converted to uppercase before they are sent to the server, because most servers require this. You can turn off
this conversion by -C.
AUTHORS
nwbpset was written by Volker Lendecke. See the Changes file of ncpfs for other contributors.
nwbpset 8/7/1996 NWBPSET(1)