how can i print all the chars of a string one by line?
i have thought that use a for cicle and use this command inside:
${VARIABLE:0:last}but how can i make last? because string is random
P.S. VARIABLE is the string
or can i make a variable for every chars of this string?
this was my idea... (10 Replies)
I want to extract the string TC from the string TC10, the string can have any characters
out of .
I used the following code but didnt get the right output. Please guide
nuc=match(val,/*/)
seq=substr(val,RSTART,RLENGTH)
---------- Post updated at 09:40 PM ---------- Previous update was... (0 Replies)
Hi I am beginner in writing shell scripting please tell me how to compare a string in Unix shell.
i have two variables in a shell script,
var1="00101 00201 00301 303 401 405"
var2="101 201 301"
i want to compare var1 with var2 . for example if 101 from Var1 present in Var2 or not. similarly... (5 Replies)
Input:
XXX:1,XXX:3,XXX:3
Output:
A=1
B=3
C=3
Below code is what i do currently. However it doesn't work out for all cases. As some times the last digit extracted is giving me error. It cant be used for arithmetic computation.
Any better methods out there? If possible, can you... (9 Replies)
Hi
I have a file which has sequences which look like this
>String1
aqwertrtrytytyuuijhgddfghhhghhgjhjhhsswekrkmygppdslxmvbnhkwqalldrtjbllnlnlnnnvc
>String2
qwwerrtyuiopasdfghjmnbvfklzxerbvcwghjjkoowwqerrtggbddqsdfgaqwcxzakjtyugfsdefrtgyhujiknbbbbcdcdcxsxsx zxzxcvcfcdcg
>String3... (5 Replies)
I am trying to execute something like this
file=/tmp/test.txt
firstline=$(head -n 1 $file)
value=`echo $firstline | cut -d'=' -f2`
if
then
echo true
fi
i read the first line of a file, cut to the numeric value in the first line and check if it greater than 2
but for some... (11 Replies)
Hi Gurus,
I need find which file contains certain string in one directory.
when using
cat * |grep "string", I can get the string name but no file name displayed.
I am wondering if there is any option I can use to get which file contains this certain string.
Thanks in advance. (3 Replies)
I apologize if it was asked before but I couldn't find something related.
I want to replace 2 strings in a file
e.g
pwddb=Lar1wod (need to replace string after =)
pwdapp=Wde2xe (need to replace string after =)
AND in same file want to find last occurrence of a string (SR2-134561),... (2 Replies)
Discussion started by: J_ang
2 Replies
LEARN ABOUT BSD
nfdump
NFDUMP(8) System Manager's Manual NFDUMP(8)NAME
nfdump, nfload - notesfile dump/load programs
SYNOPSIS
nfdump notesfile
nfload [ -Ddirectory ] notesfile
DESCRIPTION
Nfdump and nfload are used to convert notesfile data base formats.
Nfdump converts the specified notesfile to a portable ASCII format and writes it to standard output. Some diagnostics are produced on
stderr. Nfdump can be run by any user; access to a particular notesfile is governed by that notesfile's access list.
Nfload is used on the output from nfdump to create a new notesfile. The -D option specifies an alternate base directory for the notesfile.
If unspecified, this defaults to ``/usr/spool/notes''. Nfload reads standard input for the ASCII representation of the notesfile.
Typical use of these two programs occurs when converting an existing notesfile data base to a new format. The nfdump program should be
compiled with the older structure definitions while nfload is compiled with the newer structures. The data base can then be converted with
a shell script of the following nature:
mkdir .OLD
mv * .OLD
for i in `ls .OLD`
do
echo $i start
nfdump $i | nfload -D/usr/spool/newnotes $i
done
echo $i done
echo ALL DONE
rm -rf .OLD
This assumes that the old data base is in ``/usr/spool/notes'' and the new data base is to be placed in ``/usr/spool/newnotes''. After the
conversion is complete, one can move the old data base from ``/usr/spool/notes'' to ``/usr/spool/oldformat'' and the new data base from
``/usr/spool/newnotes'' to ``/usr/spool/notes''.
FILES SEE ALSO notes(1),
The Notesfile Reference Manual
AUTHORS
Ray Essick (uiucdcs!essick, essick%uiuc@csnet-relay.arpa)
Department of Computer Science
University of Illinois at Urbana-Champaign
Urbana, IL
Rob Kolstad (kolstad@convex.UUCP)
CONVEX Computer Corporation
Richardson, TX
University of Illinois NFDUMP(8)