Time for your 3rd Quarter Update! Are you in the running for the 6th Annual Expert Awards? Click the link to find out.

Third Quarter Hot Shots
 

Having problems asking a question? Have a general question about Experts Exchange? Let us know!

 
Time Tested Perl Solutions: 126 - 150 of 1903
 
Hi, I have a string of text with values enclosed by double quotes in each line of the text file. Using perl, how do i remove the double quotes but without doing any other formatting on t...
I am installing swatch (module for use by Snort) and it requires several specific modules, like date, time formatting, etc.  Using ActiveState Perl, I tried to prepare the code but the above e...
I am writing a perl script which should report the space used by a database in a single excel sheet daily, mean to say that it should append the data in the same spreadsheet. So how do I devic...
I'm using LWP::UserAgent to scrape data from a site. to hide my IP i used proxy that i found from web as they let ppl use as free. but it is not working. pls guide me what is the write way to ...
Hi I'm using an oracle db and i prepare and execute a statement that may return any number of rows. ... prepare_statement_differences(); $differences_sql -> execute; while(@differences ...
HI All, Need some help with something I'm writing and I've hit a mental block. At current I'm fetching some data from sql and have stored a hash ref for each row in an array: sub load...
I need to execute a program that is parallel to my script, but need full path to cwd.  I know how to execute it by hardcoding the cwd, but how do I get it at runtime?
Hello, I have a list of "bad words" (actually it's a list of bad URL substrings) on a website with a high traffic and I right now I am using something like the code attached... It works ...
Hi, I need to create a script that will take perl inputfile_name outputfile_name string If the inputfile has 5 lines and 3 lines contain the string then in the output file copy the ...
Is the follwowing code possible? Can you correct it (error at "keys %File")? (I get the error "Type of arg 1 to keys must be hash (not concatenation) at ..." if I try "print keys %File{$file}...
This is the code to get a y/n but when I make a subsequent call it does not ask for the input ! #! /in/local/bin/perl sub demande { my $in=0; system("echo \"Have u modified \""); $in = ...
Hello. I want to use something like: use LWP::Simple; my $var=get("$auth_url",'$username','$password') or print "<b>Warning:</b> Could not connect to the access server.<br> Please make sur...
I am doing find and replace like this find /path/to/folder -name '*.*' -print0 | xargs -0 perl -pi -e "s/3\.1\.00/8\.4\.0\.${DATE}/g" When I run the above script it works fine, but the p...
Hi I need to read in an email (source with header), and extract the sender's name, or his email address if the name is not available. For example, these are possible "From: " lines in email he...
I need a perl script that will open an existing file delete the first line and then write them back out.
Excel outputs .csv file. If the sheet cell contained a comma, the cell is quoted. .csv output:   cellone,celltwo,"cell has, comma",cell four If the sheet cell containes a quote, it's...
I'm new to Perl and have no idea how to convert aDate Format.  How can I convert a date from "Jun 20 2007 12:00AM" to "06/20/2007".  Is there a built-in Perl function (e.g. FormatDateTime() in...
how do i reset a hash table so it has nothing in it (no keys etc)...................
I am using PRINTF to format some output.  I know it is possible to justify left and right: printf '%9s',   "test";   # prints "     test" printf '%-6s',  "test";   # prints "test     " ...
Hi, i have a tab delimited input file that looks like this: Query      Score      E-Value      Position At1g01010       775      0.0      4705 At1g01010       775      0.0      4765 At1g01...
when i do $temp = `grep ooo file.txt` i print $temp; /v/apache/conf/vhost.web1:       include conf/oos_test.conf /v/apache/conf/vhost.web1:       include conf/oos_apps.conf /v/apache...
I have a $variable received from a HTML textarea form. EG: This is a test I want to remove the newlines (carrige return line feeds)from it, so that it looks like: This is a test I h...
Hi, when i run my sendmail.pl script from xyz server, it runs fine and sends the email. but when i run from different server "abc", it give me following error: Can't call method "mail" on ...
I generate an Excel spreadsheet by using the Perl module Writespreadsheet:Excel, but the string in the cell is in a "General Format" with the following data: 0.207242063 In Excel when I ch...
I have a perl script that creates a text file.  I need to append the current date to the file name.  Right now, I have a variable like this: # csv path/filename my $csvfile = "/home/mydire...