11-09-2006
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
How to insert leading zeros into a left-justisfied zip code?
e.g. Zip code is written as 60320 which is left-justified to make it be read as 0060320.
We have to move it to right-justifiable then insert 2 leading zeros into it... ;) (1 Reply)
Discussion started by: wtofu
1 Replies
2. Shell Programming and Scripting
How do I remove or add leading zeroa from a variable. To make variable 10 characters long when adding zeros. (6 Replies)
Discussion started by: toshidas2000
6 Replies
3. Shell Programming and Scripting
Hi all,
I have file with numeric values. I need to pad each value with leading zeros such that total lenght of each value is 16.
Example:
cat tmp.txt
502455
50255
5026
5027
5028
Output
0000000000502455
0000000000050255
0000000000005026
0000000000005027
0000000000005028
Any... (12 Replies)
Discussion started by: jakSun8
12 Replies
4. UNIX for Dummies Questions & Answers
Hi All,
How does one trim leading zero's in unix
Thanks
KP. (7 Replies)
Discussion started by: kingofprussia
7 Replies
5. Shell Programming and Scripting
Hi
i need help in adding leading zero to filenames
e.g file name in my folder are
1_234sd.txt
23_234sd.txt
the output i need is
001_234sd.txt
023_234sd.txt
can i do this shell scripting
please help (2 Replies)
Discussion started by: rsmpk
2 Replies
6. Shell Programming and Scripting
removing leading zeros for a decimal column in a file which has string & decimal values
,,,,,6630140,XXXXXXXXXXXXXXX, 0020.00,USA
,,,,,6630150,XXXXXXXXXXXXXXXL (xyz, 0010.00,USA
,,,,,6630150,XXXXXXXXXXXXXXX(xyz), 1300.00,USA
My file contains 9 columns. Out 9 columns, 8th column contains the... (9 Replies)
Discussion started by: marpadga18
9 Replies
7. UNIX for Dummies Questions & Answers
Hello Gurus,
Quick question. I have a file with the following records:
A~000000000000518000~SLP ~99991231~20090701~88.50~USD~CS~
A~000000000000518000~SLP ~99991231~20090701~102.00~USD~CS~
A~000000000000772000~SLP ~99991231~20100701~118.08~USD~CS~
I wold like to do the following:
1. Add... (1 Reply)
Discussion started by: chumsky
1 Replies
8. Shell Programming and Scripting
I'm using cygwin bash to submit scheduled tasks (kinda like cron jobs) in windows and the following script is giving me grief. I need to format the current time with leading zeros before 10AM for the hour field. In this example, I manually typed in "09:50" instead of using the `printf...`... (2 Replies)
Discussion started by: siegfried
2 Replies
9. Shell Programming and Scripting
Hi,
i have a variable which conatins values like 00001,0003,00067,00459.
I want to use the values one by one and in the same form as they are like 00001,0003,00067,00459.
Also can anyone tell me how to increment those numbers by 1,keeping the format as same like 00002,0004,00068,00460.... (5 Replies)
Discussion started by: arijitsaha
5 Replies
10. Shell Programming and Scripting
I have a list of numbers extracted and need to delete the leading zeros from them, but when i do so, the command I am using also deletes numbers that end in Zero as well. eg 10, 20, 30, etc
this is part of a larger script and the only way I can think of is to try and detect the 10,20 30 etc in... (19 Replies)
Discussion started by: kcpoole
19 Replies
LEARN ABOUT DEBIAN
devel::bt
Devel::bt(3pm) User Contributed Perl Documentation Devel::bt(3pm)
NAME
Devel::bt - Automatic gdb backtraces on errors
SYNOPSIS
$ perl -d:bt -MB -e'(bless (my $o = 0), q{B::SV})->REFCNT'
#0 0x00007f9c3215ab0e in __libc_waitpid (pid=<value optimized out>, stat_loc=0x7fff4c5ffbe8, options=<value optimized out>) at ../sysdeps/unix/sysv/linux/waitpid.c:32
#1 0x00007f9c319168c1 in backtrace () at bt.xs:129
#2 0x00007f9c319168ec in sighandler (sig=11) at bt.xs:135
#3 <signal handler called>
#4 0x00007f9c316c8ccf in XS_B__SV_REFCNT (my_perl=0x151c010, cv=0x177bfb8) at B.c:3360
#5 0x000000000057d5a0 in Perl_pp_entersub (my_perl=0x151c010) at pp_hot.c:2882
#6 0x000000000051a331 in Perl_runops_debug (my_perl=0x151c010) at dump.c:2049
#7 0x0000000000454ab0 in S_run_body (my_perl=0x151c010, oldscope=1) at perl.c:2308
#8 0x0000000000453d78 in perl_run (my_perl=0x151c010) at perl.c:2233
#9 0x00000000004230fd in main (argc=6, argv=0x7fff4c600788, env=0x7fff4c6007c0) at perlmain.c:117
DESCRIPTION
This module, when enabled, registers a handler for certain types of fatal errors, like segmentation faults, and, once such an error occurs,
prints a debugger backtrace to standard output before exiting the program.
It is intended to be used to debug crashes in situations where running the failing program directly under a debugger is not possible, for
example when trying to get more information from cpantesters or from users unfamiliar with gdb.
HOW IT WORKS
When being imported, a signal handler for the following signals is registered:
o "SIGILL"
o "SIGFPE"
o "SIGBUS"
o "SIGSEGV"
o "SIGTRAP"
o "SIGABRT"
o "SIGQUIT"
Once the program causes an error that results in one of the above signals being sent to it, the signal handler will be called, and fork off
a process running "gdb" and generating a backtrace of the running program, which will then be printed to standard output.
ACKNOWLEDGEMENTS
This software is based on parts of "glib", which is written by:
o Peter Mattis <petm@xcf.berkeley.edu>
o Spencer Kimball <spencer@xcf.berkeley.edu>
o Josh MacDonald <jmacd@xcf.berkeley.edu>
o Shawn T. Amundson <amundson@gimp.org>
o Jeff Garzik <jgarzik@pobox.com>
o Raja R Harinath <harinath@cs.umn.edu>
o Tim Janik <timj@gtk.org>
o Elliot Lee <sopwith@redhat.com>
o Tor Lillqvist <tml@iki.fi>
o Paolo Molaro <lupus@debian.org>
o Havoc Pennington <hp@pobox.com>
o Manish Singh <yosh@gimp.org>
o Owen Taylor <otaylor@gtk.org>
o Sebastian Wilhelmi <wilhelmi@ira.uka.de>
o and others
"glib" is licensed under The GNU Lesser General Public License, Version 2.
AUTHOR
Florian Ragwitz <rafl@debian.org>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2010 by Florian Ragwitz.
This is free software, licensed under:
The GNU Lesser General Public License, Version 2.1, February 1999
perl v5.14.2 2010-09-08 Devel::bt(3pm)