10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I am new to Scripting language.
I want to split a file and create several subfiles using Perl script.
Example :
File format :
Sourcename ID Date Nbr
SU IMYFDJ 9/17/2012 5552159976555
SU BWZMIG 9/14/2012 1952257857887
AR PEHQDF 11/26/2012 ... (13 Replies)
Discussion started by: Deepak9870
13 Replies
2. Shell Programming and Scripting
I have a perl variable which contains the below value.
$var1 = "2% / 51%"
Now I would like to split the data into 2 different variables.
For example
$part1 = 2
$part2 = 51
Could anyone please help me in this regard ?
Regards,
GS (4 Replies)
Discussion started by: giridhar276
4 Replies
3. Shell Programming and Scripting
Hello,
I'm trying to figure out why this perl command does not work.
I want to split a string on dot delimiter.
If I try with colon the result is fine:
> echo -n "hello:world" | perl -F/:/ -ane 'print "$F\n"'
>world
As expected I get the good result, but by typing:
> echo -n... (3 Replies)
Discussion started by: Dedalus
3 Replies
4. Shell Programming and Scripting
Hi,
I have a file in PERL in the following pattern
filename| 06-Dec-11 03.04.14.000000 PM
filename1| 06-Dec-11 05.05.14.000000 PM
I need to replace .(dot) with :(semicolon) in the timestamp value of the file
How can this be done. Any help will be appreciated
Thanks in advance (5 Replies)
Discussion started by: irudayaraj
5 Replies
5. Shell Programming and Scripting
Hi,
I'm trying to split a large file into several smaller files
the script will have two input arguments argument1=filename and argument2=no of files to be split.
In my large input file I have a header followed by 100009 records
The first line is a header; I want this header in all my... (9 Replies)
Discussion started by: ramky79
9 Replies
6. Shell Programming and Scripting
Hi there,
I have an output from a command like this
# ypcat -k netgroup.byuser| grep steven
steven.* users_main,users_sysadmin,users_global,users_backup_team
and wanted to pull the 'users' netgroups returned into a perl array, that will look like this
users_main... (2 Replies)
Discussion started by: rethink
2 Replies
7. Shell Programming and Scripting
If i have a script name.pl
I run it like name.pl -v file.txt -t ext2 -u user -j
how can I edit the array @ARGV so when my script calls
$ARGV = -v file.txt
$ARGV = -j (2 Replies)
Discussion started by: 3junior
2 Replies
8. Shell Programming and Scripting
Hi Friends,
I have a variable which has a number (e.g. 12.1234). I want to remove "." (dot) from that number i.e. 121234
I want to do this using perl.
Can you please guide me
Thank you
Anushree (2 Replies)
Discussion started by: anushree.a
2 Replies
9. Shell Programming and Scripting
Hi,
I am extracting SQL queries into a file and the file is as follows
*********************************************************
select BatchKey ,restartStatus ,batchContextBuffer ,batchPgmId ,StartKey ,
EndKey ,Mcbatchcontrol_ver
from
qsecminload.Mcbatchcontrol_t where RefId = :1 ... (5 Replies)
Discussion started by: sagarbsa
5 Replies
10. Shell Programming and Scripting
Let's say I have a very long string with no spaces but just words stored in $very_long_string.
$very_long_string = "aaaaaaaaaaabbbbbbbbbbbccccccccccccdddddddddddd";
I can do this to split the string into 1 character each and store them in an array:
@myArray = split(//, $very_long_string); ... (3 Replies)
Discussion started by: teiji
3 Replies