Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

~5K People Reached
Favorite Tags
Member Avatar for RingmasterTJ

Hi All, I'm a bit of a noobie to Perl, & am working on porting a Perl based web app from an old Sun box to a virtually hosted Windows box. The Windows box is (as far as I know) 2008R1 & running IIS 7.0, the version of Perl is …

Member Avatar for voidyman
0
245
Member Avatar for voidyman

Below code snippet when executed from within a perl script, gives only $datetime."12/31/9999,AUTO,.$datetime as ouput. my $datetime=`date "+%D %r"`; open(FIN,"<$file_in") or die $!."\n"; open(FOUT,">$file_out") or die $!."\n"; my @lines=<FIN>; close(FIN); foreach(@lines){ $msg=$_; chomp($msg); $msg=$msg.",".$datetime.",12/31/9999,AUTO,".$datetime; print FOUT $msg."\n"; } close(FOUT); If i remove the chomp though, it gives me the line …

Member Avatar for voidyman
0
131
Member Avatar for DJSarma

Please help me!I want the code for doing following task in perl. Task is that "Read the paragraph from a file and print it in another file in ascending(total number of words in a sentence) order." My sample task: If the input "Hi! my name is Sarma. Can you help?" …

Member Avatar for voidyman
0
573
Member Avatar for voidyman

[CODE] #!opt/local/bin/perl5 use strict; use Spreadsheet::ParseExcel; use XLSX.pm; my $oExcel = new Spreadsheet::ParseExcel; die "You must provide a filename to $0 to be parsed as an Excel file" unless @ARGV; my $oBook = $oExcel->Parse($ARGV[0]); my($iR, $iC, $oWkS, $oWkC); print "FILE :", $oBook->{File} , "\n"; print "COUNT :", $oBook->{SheetCount} , "\n"; …

Member Avatar for 2teez
0
387
Member Avatar for voidyman

I want to know what exactly a DBreorg does.My understanding is that it recalculates the data distributions based on index. But how is this different from a update stats on a table? I understand that we have two types of reorg 1)online and 2)offline. Whats the differnce? Apologies, I dunno …

Member Avatar for pritaeas
0
90
Member Avatar for biojet

Hello, Could you please help me in following scenario in Perl scripting? I want to compare two text files & change the charter at the position. Output of this comparision in third file with flags C-CHANGE, N-SAME at the end of line. [CODE]IN PUT1: Posi 3 ATG 2 ACT 1 …

Member Avatar for biojet
0
155
Member Avatar for chandbasha

Hi I have one sql query. using this query i can download 10 lakhs of data in csv file for 6 hours. now i want to download 20 lakhs of data for 6 hours or less. please tell me how to increase the performance. SELECT id as imp_addr_id,userEmail, email ,name,mobile_no,gender,city,income,profession,experience,country,pincode,type …

Member Avatar for fobos
1
235
Member Avatar for sandeepau

Hello, Can someone tell me the equivalent perl script/command for following unix command: sort -t"|" -k1,1 -T '/temp' input.txt > output.txt Here, I want mention different physical directory for temprary sort file storage. like - T in unix shell command. In other word, How to mention different workspace directory in …

Member Avatar for voidyman
0
384
Member Avatar for voidyman

Hi, Am trying to copy all the directories alone within a directory. I tried something like [CODE] ls -ltr | awk '$1 ~/^d/{print $8} ' | xargs cp -r dest_dir [/CODE] the first part [CODE]ls -ltr | awk '$1 ~/^d/{print $8} ' [/CODE] gives O/P Testing But it keeps saying …

Member Avatar for rubberman
0
68
Member Avatar for b1izzard

How to list out i"dle users only" using finger command? (Commandline) [CODE] $finger Login Name Tty Idle Login Time Where ravikumar ravikumar *:0 - Sun 19:54 console ravikumar ravikumar *pts/0 2:36 Sun 19:56 ravikumar ravikumar *pts/1 - Sun 22:08 $ finger | tr -s " " | sort -k 4 …

Member Avatar for b1izzard
0
648
Member Avatar for brax4444

Hello all, I'm trying to read in an entire tab-delimited files with the following data layout: File Title Line is always at the top. DataName1 DataNam2 DataName3 12345 123.4 12.456 9876 987.65 45678 There may be any number of rows and columns after the title line. I want to read …

Member Avatar for voidyman
0
465
Member Avatar for voidyman

I want to remove blank lines (empty or with spaces and tabs) from a file from within a perl script. here's what i tried. [CODE]`sed '/^ *\$/d' $file1`;[/CODE] Does not seem to work for some reason. Any Help please?

Member Avatar for voidyman
0
851
Member Avatar for newbie14

Dear All, I have a query as below SELECT DISTINCT (productID),totalAmountAfter,transactionDate FROM tbltransaction WHERE transactionDate BETWEEN '2010-01-01' AND '2010-12-31' ORDER BY productID,transactionDate DESC . My problem now I want is that for each product only pick one line that is the last line since I have ordered by the date. …

Member Avatar for smantscheff
0
101
Member Avatar for voidyman

Hi, Is there a way i can pass variable column names to a stored proc? Here's what i want to do: i have lots of tables and for each of those i want to select out a few columns. e.g from table titles i want to pick out title_name and …

Member Avatar for debasisdas
0
609
Member Avatar for voidyman

Hi i want to grep for two different patterns in the same file and diff the results(without needing to store them) I amnot able to get diff to accept the output of the two greps as arguments. Any help? Thanks for your time.

Member Avatar for AnkushChander
0
122
Member Avatar for voidyman

Hi, I want to ftp a file to a location and then kickstart a process there to work on the file. I tried using !rexec but it does not seem to be working too well. I am not using the .netrc file(if that helps you understand my problems better) Thanks …

Member Avatar for voidyman
0
98