08-19-2008
why convert 8 space to 1 tab character on unix?
Hi everybody,
I'm using Hp unix tru64.
I have generate one file from shell script.
bus that file content pre "8 space char" convert one tab character.
why?
result file hex format:
hex 20 20 20 20 20 to 09
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
no problem (6 Replies)
Discussion started by: angelina
6 Replies
2. Shell Programming and Scripting
hey i m newbie i dont know whether this is happining in my terminal or is there any reason behind this
here it is
when i do
1.) sed -n 's/\t/\n/gp' space > enter #where space is tab seperated file
it works fine it give me a outupt that all tab seperated convert into column
but when i... (3 Replies)
Discussion started by: narang.mohit
3 Replies
3. Shell Programming and Scripting
Hi,
We have a couple of ms excel files in unix server.We need convert the excel files to files TAB limiter format file with using unix script.
Could you please advise on this (2 Replies)
Discussion started by: koti_rama
2 Replies
4. Shell Programming and Scripting
I have a file with different record length. The file as to be converted into fixed length by appending spaces at the end of record. The length should be calculated based on the record with maximum length in the file.
If the length is less than the max length, the spaces should be appended... (4 Replies)
Discussion started by: Amrutha24
4 Replies
5. UNIX for Dummies Questions & Answers
Hi,
I have a space delimited text file but I only want to change the first space to a tab and keep the rest of the spaces intact. How do I go about doing that? Thanks! (3 Replies)
Discussion started by: evelibertine
3 Replies
6. Shell Programming and Scripting
Hello,
I have a text file with space and tab (mixed) delimited file and need to convert into CSV.
# cat test.txt
/dev/rmt/tsmmt32 HP Ultrium 6-SCSI J3LZ 50:03:08:c0:02:72:c0:b5 F00272C0B5 0/0/6/1/1.145.17.255.0.0.0 /dev/rmt/c102t0d0BEST
/dev/rmt/tsmmt37 ... (6 Replies)
Discussion started by: prvnrk
6 Replies
7. UNIX for Beginners Questions & Answers
I have variable that contains multiple values of number and also include overpunch(i.e. # $ % etc) character so we want to replace it with numbers.
here are the example:
Code:
11500#.0#
28575$.5$
527#.7#
42".2"
2794 .4
2279!.9!
1067&.7&
926#.6#
2279!.9!
885".5"
11714$.4$
27361'.1'... (1 Reply)
Discussion started by: nadeemrafikhan
1 Replies
8. UNIX for Beginners Questions & Answers
Script showStreamsGLIS$reg.$env.ksh gives me output as below-
Job Stime Etime Status ExitCode
GLIS-AS-S-EFL-LOCK-B ----- ----- OI 103313880/0
GLIS-ALL-Q-EOD-FX-UPDT-1730-B ----- ----- TE 0/0
GLIS-TK-S-BWSOD-B ... (8 Replies)
Discussion started by: Tanu
8 Replies
9. Shell Programming and Scripting
Hello,
I have an excel sheet (.xlsx), with 11 worksheets. I need to run my bash scripts on the 1st worksheet and write the output to the 2nd worksheet.
I am currently manually converting the worksheet into a tab delimited to run the script and then pasting it back to excel.
Is there a way to do... (2 Replies)
Discussion started by: nans
2 Replies
10. Shell Programming and Scripting
I have a variable like below:
str1="10.9.11.128\n-rwxr-xr-x user1 2019-12-29 17:53 /var/branch/custom/tg.xml 286030210\n10.9.12.129\n-rwxr-xr-x user1 2019-12-29 17:53 /app/branch/custom/tg.xml 286030210\n10.9.20.130\n-rwxr-xr-x user1 2019-12-29 17:53 /web/branch/custom/tg.xml 286030210"
I... (8 Replies)
Discussion started by: mohtashims
8 Replies
LEARN ABOUT DEBIAN
netsds::util::convert
NetSDS::Util::Convert(3pm) User Contributed Perl Documentation NetSDS::Util::Convert(3pm)
NAME
NetSDS::Util::Convert - data formats conversion functions
SYNOPSIS
use NetSDS::Util::Convert qw(...);
DESCRIPTION
"NetSDS::Util::Convert" module contains miscelaneous functions.
o CLI parameters processing
o types validation
o HEX, Base64, URI, BCD encondig
o UUID processing
EXPORTED FUNCTIONS
conv_conv_str_bcd($str) - convert string to little-endian BCD
This function converts string to little-endian BCD encoding filled with F16 value.
conv_chr_hex($char) - encode char to hexadecimal string
$hex = conv_chr_hex('a'); # return 61
conv_hex_chr($hex) - convert hexadecimal string to character
$chr = conv_hex_chr('4A'); # return 'J'
conv_str_hex($str) - convert byte string to hexadecimal
$str = 'Want hex dump!';
$hex = conv_hex_str($str);
print "Hex string: " . $hex;
conv_hex_str($string) - convert hex to byte string
$hex = '7A686F7061';
$string = conv_hex_str($hex);
print "String from hex: " . $string;
conv_str_base64($str) - convert string to Base64
my $b64 = str_base64("Hallo, people!");
conv_base64_str($b64) - convert Base64 to string
my $str = base64_str($base64_string);
conv_str_uri($str) - convert string to URI encoded
Example:
my $uri = str_uri("http://www.google.com/?q=what");
conv_uri_str($uri) - decode URI encoded string
Example:
my $str = uri_str($uri_string);
EXAMPLES
None
BUGS
None
TODO
1. Add other encodings support
SEE ALSO
Pod::Usage, Data::UUID
AUTHORS
Valentyn Solomko <pere@pere.org.ua>
Michael Bochkaryov <misha@rattler.kiev.ua>
perl v5.12.4 2011-08-27 NetSDS::Util::Convert(3pm)