10 More Discussions You Might Find Interesting
1. HP-UX
OK, so I just messed myself up. Thinking the /var/opt/ignite/data/INDEX files was static, I manually edited the file and added 2 more OS's to it. During an Install it only showed the first OS (started with 11.31, 3 versions then added a 11.23, and a 11.11 stanza's).
The 11.23 and 11.11 never... (2 Replies)
Discussion started by: mrmurdock
2 Replies
2. Shell Programming and Scripting
i have one file which contains data like the below
DE_CODE|AXXANY|APP_NAME|TELCO|LOC|NY
DE_CODE|AXXATX|APP_NAME|TELCO|LOC|TX
DE_CODE|AXXABT|APP_NAME|TELCO|LOC|BT
DE_CODE|AXXANJ|APP_NAME|TELCO|LOC|NJ
DE_CODE|AXXANJwt|APP_NAME|TELCO|LOC|WT
am going use a for loop or whole loop which will... (3 Replies)
Discussion started by: mail2sant
3 Replies
3. Shell Programming and Scripting
i would like to search for a letter in a string and get its index position.
example:
name='john'
pos=$(expr index $name o)
the result will be equal to 2 (2nd position)
how do you make this thing not case sensitive?
example:
name='john'
pos=$(expr index $name O)
the... (1 Reply)
Discussion started by: kokoro
1 Replies
4. Shell Programming and Scripting
I'm trying to figure out a way to store the index value from a flat file. The flat file looks like this:
A1,A2,A4,A6,B3,B6,B7,C1,C2,C5,C7,D2,D5,D7,E2,E3,E4,F1,F5,F6,G2,G5
What I'm trying to achieve is to grab individual index value so as to display it out in a 7x7 matrix with ROW and COL... (21 Replies)
Discussion started by: vinzping
21 Replies
5. OS X (Apple)
I was wondering about the "Show Package Contents" option in OS X. I have a keynote file that I'm looking at. Exactly where are these contents or its directory stored, because they aren't visible in the Finder window, unless I obviously right click and choose to view them. And I don't think I can... (2 Replies)
Discussion started by: Straitsfan
2 Replies
6. Solaris
I know how to check if any file has a unix process using a file by looking at 'lsof <fullpath/filename>' command.
I think using lsof is very expensive. Also to make it accurate we need to inlcude fullpath of the file.
Is there another command that can tell if a file has a truely active... (12 Replies)
Discussion started by: kchinnam
12 Replies
7. AIX
Hello, I'm trying to build a (bff) package from an already installed program (clam antivirus) using mkinstallp. However, mkinstallp fails with "no such file: ./usr/lpp/<package name>/inst_root"
I'm not sure why all files get created ok except for these particular ones. Any help would be... (2 Replies)
Discussion started by: omonte
2 Replies
8. Shell Programming and Scripting
Hi Folks,
Under the path /home, I need to remove the index.html/php files from all the users. But the thing is I need to move the index file from the username starting with a-d, then e-g. How can I do this via the shell script. (2 Replies)
Discussion started by: gsiva
2 Replies
9. Filesystems, Disks and Memory
why do inode indices starts from 1 unlike array indexes which starts from 0
its a question from "the design of unix operating system" of maurice j bach
id be glad if i get to know the answer quickly
:) (0 Replies)
Discussion started by: sairamdevotee
0 Replies
10. Shell Programming and Scripting
I want to deal with several data, i.e., data.*.txt with following structure
MSG|20010102|123 125 4562 409|SEND
MSG|20010102|120 230|SEND
MSG|20010102|120 204 5071|SEND
MSG|20010103|2 11 1098 9810|SEND
......
index file index.txt is
11
201
298
100
......
What I want to do is:
1)... (0 Replies)
Discussion started by: zhynxn
0 Replies
CheckDigits::MBase_003(3pm) User Contributed Perl Documentation CheckDigits::MBase_003(3pm)
NAME
CheckDigits::MBase_003 - compute check digits for SICI (Serial Item and Contribution Identifier)
SYNOPSIS
use Algorithm::CheckDigits;
$sici = CheckDigits('sici');
if ($sici->is_valid('0784-8679(20040308)6:<138>2.0.TX;2-H')) {
# do something
}
$cn = $sici->complete('0784-8679(20040308)6:<138>2.0.TX;2-');
# $cn = '0784-8679(20040308)6:<138>2.0.TX;2-H'
$cd = $sici->checkdigit('0784-8679(20040308)6:<138>2.0.TX;2-H');
# $cd = 'H'
$bn = $sici->basenumber('0784-8679(20040308)6:<138>2.0.TX;2-H');
# $bn = '0784-8679(20040308)6:<138>2.0.TX;2-';
DESCRIPTION
ALGORITHM
0 In the string describing the number all letters (A-Z) are replaced with numbers 10-35 accordingly. All other non-numbers are replaced
by 36.
1 Beginning right the numbers at all odd positions are added.
2 The sum from step 1 is multiplied by 3.
3 Beginning right the numbers at all even positions are added.
4 The sums from step 2 and 3 are added.
5 The sum from step 4 is taken modulo 37.
6 The checksum is 37 minus the sum from step 5 where numbers from 10 to 35 are represented by 'A' to 'Z' accordingly and 36 is
represented by '#'.
METHODS
is_valid($number)
Returns true only if $number consists solely of numbers and hyphens and the two digits in the middle are valid check digits according
to the algorithm given above.
Returns false otherwise,
complete($number)
The check digit for $number is computed and inserted into the middle of $number.
Returns the complete number with check digit or '' if $number does not consist solely of digits, hyphens and spaces.
basenumber($number)
Returns the basenumber of $number if $number has a valid check digit.
Return '' otherwise.
checkdigit($number)
Returns the check digits of $number if $number has valid check digits.
Return '' otherwise.
EXPORT
None by default.
AUTHOR
Mathias Weidner, <mathias@weidner.in-bad-schmiedeberg.de>
SEE ALSO
perl, CheckDigits, www.pruefziffernberechnung.de, http://sunsite.berkeley.edu/SICI/sici.pdf
perl v5.10.0 2008-05-17 CheckDigits::MBase_003(3pm)