Thanks - now all I need to do is swap the order so the newline comes before the "<".
---------- Post updated at 11:30 AM ---------- Previous update was at 10:43 AM ----------
I got it to work in three separate nawk command lines. Any way to concat them into a single command line?
set 1 - process occurences of ><
set 2 - process occurences of >
set 3 - process occurrences of <
This User Gave Thanks to Don Cragun For This Post:
#!/bin/ksh
VAR_ONE=HELLO
TEMP=ONE
echo $VAR_${TEMP}
## Output is: ONE
Hi, I want the output to echo HELLO and not ONE as the above script does. I know I am missing something with dollar substitution. Can anyone help me out ?
Thanks.
Cal (4 Replies)
I have a report which contains the following:
Count Value %
47 69.12
18 26.47
3 4.41
I want to grep the total on the bottom brackets and store in a variable. However this may have a different figure everyday.
To read the i do:
... (1 Reply)
Hi ,
I have have file which has following structure
01aaaa88888000-9999
01ssss77777000-0991
01ssss7777700000991
02ssss7777700000991
The record 01 is corrupt as value from 12th field to 19th should be positive or start with - however it is 000-9999 it should be -0009999
i need to... (4 Replies)
Hello everyone ...
I'm going crazy, I hope some of you can help me ...
I have to replace a line in a crontab like this:
5 2 * * 2 root backupdat
with this:
5 5 * * 3 root backupdat
the command I use is the following:
sed -i.bak -e 's/5 2 * * 2 root backupdat/5 5 * * 3 root... (4 Replies)
Hi All,
I am seeing an issue while using toupper in nawk. Below is the code that I am using.Toupper method is not working as expected in this case.nawk 'NR==FNR{a=$4" "$5}NR>FNR{print NF?$0:a"\n";if(/^cn:/) x=toupper($0)}' FS="" id_list.txt attributes.txt > out
In the above script, id_list... (9 Replies)
Hi all
Having issue with substitution using sed
Trying to assign the absolute path of the file to the variable 'floc' returned by the find command
floc=`find / -name $fname`
eg cat $floc '/root/samplecheck/myfile'
I want to replace '/' with '->' in the 'floc' i am using the below sed... (2 Replies)
Hi,
Below work fine, whenever any character puts, however if we use "(", it's not working.
Working
===============
echo 'Sau(rabh is Nice' | nawk -v a="Saurabh" '{print substr($1,1,match($1, "u"))}'
Not working
====================
echo 'Sau(rabh is Nice' | nawk -v a="Saurabh" '{print... (3 Replies)
#ifconfig -a | nawk '/1.1.1.1/{print}'
inet 1.1.1.1 netmask xxxxxxxxx broadcast 0.0.0.0
If i assign the ip to a variable and search for the variable nothing gets printed!!
# ifconfig -a | nawk -v ip=1.1.1.1 '/ip/{print}'
I am not able to understand why this is happening! (6 Replies)
Hi All,
I am using the below script which has awk command, but it is not returing the expected result. can some pls help me to correct the command.
The below script sample.ksh should give the result if the value of last 4 digits in the variable NM matches with the variable value DAT. The... (7 Replies)
Discussion started by: G.K.K
7 Replies
LEARN ABOUT OSX
locale::codes::langfam
Locale::Codes::LangFam(3pm) Perl Programmers Reference Guide Locale::Codes::LangFam(3pm)NAME
Locale::Codes::LangFam - standard codes for language extension identification
SYNOPSIS
use Locale::Codes::LangFam;
$lext = code2langfam('apa'); # $lext gets 'Apache languages'
$code = langfam2code('Apache languages'); # $code gets 'apa'
@codes = all_langfam_codes();
@names = all_langfam_names();
DESCRIPTION
The "Locale::Codes::LangFam" module provides access to standard codes used for identifying language families, such as those as defined in
ISO 639-5.
Most of the routines take an optional additional argument which specifies the code set to use. If not specified, the default ISO 639-5
language family codes will be used.
SUPPORTED CODE SETS
There are several different code sets you can use for identifying language families. A code set may be specified using either a name, or a
constant that is automatically exported by this module.
For example, the two are equivalent:
$lext = code2langfam('apa','alpha');
$lext = code2langfam('apa',LOCALE_LANGFAM_ALPHA);
The codesets currently supported are:
alpha
This is the set of three-letter (lowercase) codes from ISO 639-5 such as 'apa' for Apache languages.
This is the default code set.
ROUTINES
code2langfam ( CODE [,CODESET] )
langfam2code ( NAME [,CODESET] )
langfam_code2code ( CODE ,CODESET ,CODESET2 )
all_langfam_codes ( [CODESET] )
all_langfam_names ( [CODESET] )
Locale::Codes::LangFam::rename_langfam ( CODE ,NEW_NAME [,CODESET] )
Locale::Codes::LangFam::add_langfam ( CODE ,NAME [,CODESET] )
Locale::Codes::LangFam::delete_langfam ( CODE [,CODESET] )
Locale::Codes::LangFam::add_langfam_alias ( NAME ,NEW_NAME )
Locale::Codes::LangFam::delete_langfam_alias ( NAME )
Locale::Codes::LangFam::rename_langfam_code ( CODE ,NEW_CODE [,CODESET] )
Locale::Codes::LangFam::add_langfam_code_alias ( CODE ,NEW_CODE [,CODESET] )
Locale::Codes::LangFam::delete_langfam_code_alias ( CODE [,CODESET] )
These routines are all documented in the Locale::Codes::API man page.
SEE ALSO
Locale::Codes
The Locale-Codes distribution.
Locale::Codes::API
The list of functions supported by this module.
http://www.loc.gov/standards/iso639-5/id.php
ISO 639-5 .
AUTHOR
See Locale::Codes for full author history.
Currently maintained by Sullivan Beck (sbeck@cpan.org).
COPYRIGHT
Copyright (c) 2011-2012 Sullivan Beck
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.16.2 2012-10-11 Locale::Codes::LangFam(3pm)