Hi folks
I want to update a bunch of files in a folder so that none of them start with numbers. The files names currently use this format: "0001-File-A.doc", "0002-File-B.doc", etc.
What...
I am retreiving a date field from a file which is in this format mm/dd/yyyy. I need to compare this with current date and report an error when the date retrieved is not current. Please advise.
Hey folks I have a string like this in an email header:
"Joe bob" <joe@bob.com>
How do I match just Joe Bob without the quotes? I've started with this:
m/^From:\s+"?([^"].*?)"?.*\n/i
I have a Perl program, how can I make a subroutine to run whenever an error or timeout is occurred?
Suppose one of the statement is timed-out, when it is happened, it should only call mytim...
My Perl knowledge is very limited (to say the least) and I'm wanting to do an equivalent of a vba mid/instring.
I have a string which could be as follows:
mystring=123456-blah
or
myst...
I need to parse a file whose contents are
SQL*Plus: Release 10.2.0.1.0 - Production on Thu Mar 13 19:18:01 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected t...
Can we pass
use statements through an variable?
eg
use Association;
my $Association=new Association;
rather than having the word "Association" hardcorded in perl file. i want to be able ...
Hi guys hope u can help.
What id like to do is the following....
Id like to create a perl script and dump it in the root directory of my H:\ drive.
What this script will do is the fol...
I'm working on some data manipulation tasks involving flat text files. Its getting very difficult since I have to manually count the positions in my source and output files to verify that the ...
I need to get the correct syntax to pass a variable in my perl variable construction.
The following:
my ($sql) = qq{
select [dba primary], [dba backup] from dbo.tbl_SQL_ServerDBInventor...
Hi,
I'm creating an associative array by:
$xml_array{$xml_date} = $xml_text;
where $xml_date is in the format of year-month-day i.e. 2008-03-08 and $xml_text is a text string.
I ca...
How to send Control C to Telnet?
Hi,
I'm trying to run a perl script that connects to a MsSQL db which holds all the information for our customer base. The following is the code:
#!/usr/bin/perl -w
use DBI;
my $db...
What is the equivalent perl module for Win32::OLE on UNIX?
I have two files:
file 1:
JOHN N/A N/A 0:05 0:30 2:00 Still running
HARRY CALIF client006 2:30 4:00 4:24 4:39 10:54:46 10:54:46
file 2:
Name...
my $Book = $Excel->Workbooks->Open($abs_path) || die "Error: File can not be opened $gFile \n";
Can't call method "Open" on an undefined value for the above line
I printed the $abs_path and...
I need to parse a txt file and get paragraphs of text into variables.
e.g.
Title: asdas asdas das dasd
asdasdas asdasdas asdasdsa
asdsada asdasdas asdasdasd
Lic: AJHSJD76767a6
A...
I need a perl script that will merge 2 or more flat text files. So for instance, if I have two files:
File1 content:
john doe 12/25/68 M
File2 content:
jane smith 03/23/78 ...
I am reading the client info from a file and then looking for whether these processes exist for the client.
Server, Position, DV01r, Dfltr, JFlow, JServer, Order. I need to look for all the...
I'm trying extract the lines from the contents of a textfile. It works halfway. Given the contents of the textfile below:
Perl is a good language to learn
but it takes a little time to g...
Hello everyone...I was wondering if someone could help me with my code. I'm trying to output just the word matching a given but it keeps printing all the lines...
the text file contents:
...
I use a Perl script to create a text-file dump from an rdf file.
The rdf file is about 2 gig and contains much content that I do NOT need. The text file should contain much LESS content. H...
I'm trying to do the following manipulations with a perl script. I have source and output text files, and I'm trying to pull strings from certain positions in the source file and append to cer...
I'm fairly new to Perl and this has me stuck. I have to perform several different tasks on some data. An example of the data (which at the moment is a txt file but will probably come from exce...
Hi,
I have a perl script (WINDOWS environment) which copies few files from a shared drive (remote server) to a local machine.
If I execute this perl script from command prompt it works per...