02-03-2012
Quote:
Originally Posted by
radoulov
Yes.
Do you want to compare the absolute numeric values of the rest of the columns?
Yes.
And also, instead of alphabets in the first three columns, I might have some numbers too.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hey guys, I have two files both with two columns, I have already created an
awk code to ignore certain lines (e.g lines that start with 963) as they wou
ld begin with a certain string, however, the rest I have added together and
calculated the average.
At the moment the code also displays... (3 Replies)
Discussion started by: chlfc
3 Replies
2. Shell Programming and Scripting
I have two files like this:
#FILE 1
ABCD 4322 26485
JMTJ 5311 97248
XMPJ 4321 58978
#FILE 2
ABCD 4321 26485
JMTJ 5311 97248
XMPJ 4321 68978
What to do: Compare the two files and find those lines that doesn't match. And have a new file like this:
#FILE 3
"from file 1"
ABCD 4322 26485... (11 Replies)
Discussion started by: kingpeejay
11 Replies
3. Shell Programming and Scripting
Hi,
i have an input text file like this:
Student 1
maths
science
=
Student 2
maths
science
=
Student 3
maths
science
i would like to print each student information into separate files, each student id is separated by "=". (1 Reply)
Discussion started by: saint2006
1 Replies
4. Shell Programming and Scripting
Hi.
I have a tab separated file that has a couple nearly identical lines. When doing:
sort file | uniq > file.new
It passes through the nearly identical lines because, well, they still are unique.
a)
I want to look only at field x for uniqueness and if the content in field x is the... (1 Reply)
Discussion started by: rocket_dog
1 Replies
5. Shell Programming and Scripting
hi
my problem is little complicated one. i have 2 files which appear like this
file 1
abbsss:aa:22:34:as akl abc 1234
mkilll:as:ss:23:qs asc abc 0987
mlopii:cd:wq:24:as asd abc 7866
file2
lkoaa:as:24:32:sa alk abc 3245
lkmo:as:34:43:qs qsa abc 0987
kloia:ds:45:56:sa acq abc 7805
i... (5 Replies)
Discussion started by: anurupa777
5 Replies
6. Shell Programming and Scripting
Good morning all,
I have a problem that is one step beyond a standard awk compare.
I would like to compare three files which have several thousand records against a fourth file. All of them have a value in each row that is identical, and one value in each of those rows which may be duplicated... (1 Reply)
Discussion started by: nashton
1 Replies
7. UNIX for Dummies Questions & Answers
I would like to print unique lines without sort or unique. Unfortunately the server I am working on does not have sort or unique. I have not been able to contact the administrator of the server to ask him to add it for several weeks. (7 Replies)
Discussion started by: cokedude
7 Replies
8. Shell Programming and Scripting
Hi,
I have multiple files that each contain one column of strings:
File1:
123abc
456def
789ghi
File2:
123abc
456def
891jkl
File3:
234mno
123abc
456def
In total I have 25 of these type of file. (5 Replies)
Discussion started by: owwow14
5 Replies
9. Shell Programming and Scripting
Hello,
I would like to ask for help with csh script.
An example of an input in .txt file is below, the number of lines varies from file to file and I have 2 or 3 columns with values. I would like to read all the values (probably one by one) and set them to independent unique variables that... (7 Replies)
Discussion started by: FMMOLA
7 Replies
10. UNIX for Beginners Questions & Answers
I have a directory of files, I can show the number of lines in each file and order them from lowest to highest with:
wc -l *|sort
15263 Image.txt
16401 reference.txt
40459 richtexteditor.txt
How can I also print the number of unique lines in each file?
15263 1401 Image.txt
16401... (15 Replies)
Discussion started by: spacegoose
15 Replies
LEARN ABOUT PHP
mb_convert_kana
MB_CONVERT_KANA(3) 1 MB_CONVERT_KANA(3)
mb_convert_kana - Convert "kana" one from another ("zen-kaku", "han-kaku" and more)
SYNOPSIS
string mb_convert_kana (string $str, [string $option = "KV"], [string $encoding = mb_internal_encoding()])
DESCRIPTION
Performs a "han-kaku" - "zen-kaku" conversion for string$str. This function is only useful for Japanese.
PARAMETERS
o $str
- The string being converted.
o $option
- The conversion option. Specify with a combination of following options.
Applicable Conversion Options
+-------+---------------------------------------------------+
|Option | |
| | |
| | Meaning |
| | |
+-------+---------------------------------------------------+
| | |
| r | |
| | |
| | Convert "zen-kaku" alphabets to "han-kaku" |
| | |
| | |
| R | |
| | |
| | Convert "han-kaku" alphabets to "zen-kaku" |
| | |
| | |
| n | |
| | |
| | Convert "zen-kaku" numbers to "han-kaku" |
| | |
| | |
| N | |
| | |
| | Convert "han-kaku" numbers to "zen-kaku" |
| | |
| | |
| a | |
| | |
| | Convert "zen-kaku" alphabets and numbers to |
| | "han-kaku" |
| | |
| | |
| A | |
| | |
| | Convert "han-kaku" alphabets and numbers to |
| | "zen-kaku" (Characters included in "a", "A" |
| | options are U+0021 - U+007E excluding U+0022, |
| | U+0027, U+005C, U+007E) |
| | |
| | |
| s | |
| | |
| | Convert "zen-kaku" space to "han-kaku" (U+3000 |
| | -> U+0020) |
| | |
| | |
| S | |
| | |
| | Convert "han-kaku" space to "zen-kaku" (U+0020 |
| | -> U+3000) |
| | |
| | |
| k | |
| | |
| | Convert "zen-kaku kata-kana" to "han-kaku kata- |
| | kana" |
| | |
| | |
| K | |
| | |
| | Convert "han-kaku kata-kana" to "zen-kaku kata- |
| | kana" |
| | |
| | |
| h | |
| | |
| | Convert "zen-kaku hira-gana" to "han-kaku kata- |
| | kana" |
| | |
| | |
| H | |
| | |
| | Convert "han-kaku kata-kana" to "zen-kaku hira- |
| | gana" |
| | |
| | |
| c | |
| | |
| | Convert "zen-kaku kata-kana" to "zen-kaku hira- |
| | gana" |
| | |
| | |
| C | |
| | |
| | Convert "zen-kaku hira-gana" to "zen-kaku kata- |
| | kana" |
| | |
| | |
| V | |
| | |
| | Collapse voiced sound notation and convert them |
| | into a character. Use with "K","H" |
| | |
+-------+---------------------------------------------------+
o $encoding
-The $encoding parameter is the character encoding. If it is omitted, the internal character encoding value will be used.
RETURN VALUES
The converted string.
EXAMPLES
Example #1
mb_convert_kana(3) example
<?php
/* Convert all "kana" to "zen-kaku" "kata-kana" */
$str = mb_convert_kana($str, "KVC");
/* Convert "han-kaku" "kata-kana" to "zen-kaku" "kata-kana"
and "zen-kaku" alpha-numeric to "han-kaku" */
$str = mb_convert_kana($str, "KVa");
?>
PHP Documentation Group MB_CONVERT_KANA(3)