Re: Best way to parse this type of data.

2011-07-12 Thread shadow52
Hello Everyone, Thanks for all the help the 3 examples were what I needed and took care of the problem in 3 different ways. Thanks for the reference to the perl parsing site a great read so far. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail:

suggest me a perl script

2011-07-12 Thread Narasimha Madineedi
Hi everyone, i have a file contains the following data. A,1,B A,2,B B,3,C B,1_1,A A,2,D C,3_3,B B,2_2,A D,2_2,A for example A,1,B its a request message ,corresponding response message will be B,1_1,A somewhere in the file. I have to sort the file in such a manner that after each request

Re: suggest me a perl script

2011-07-12 Thread Jon Hermansen
Should be trivial to do in Perl (I won't provide code), but I always use sed for jobs like these: $ echo 'A,1,B A,2,B B,3,C B,1_1,A A,2,D C,3_3,B B,2_2,A D,2_2,A' | sed 'N; s/\n/: /' A,1,B: A,2,B B,3,C: B,1_1,A A,2,D: C,3_3,B B,2_2,A: D,2_2,A On Tue, Jul 12, 2011 at

Re: help: segmentation fault in threads program that use binmode

2011-07-12 Thread a b
Hi, did you got your issue resolved!! I also face segmentation fault but without binmode I didn't found any solution any where and opted another solution my program was using thread in loop till perl dump core with Out of memory issue Best of luck ~a b On Thu, Jun 9, 2011 at 5:32 AM, anders

Re: suggest me a perl script

2011-07-12 Thread Rob Dixon
On 12/07/2011 08:44, Narasimha Madineedi wrote: Hi everyone, i have a file contains the following data. A,1,B A,2,B B,3,C B,1_1,A A,2,D C,3_3,B B,2_2,A D,2_2,A for example A,1,B its a request message ,corresponding response message will be B,1_1,A somewhere in the file. I have to sort the

XML suggestions

2011-07-12 Thread Doug Bradbury
Does anyone have suggestions for an active and easy to use XML building parsing module? Doug Bradbury -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: XML suggestions

2011-07-12 Thread Rob Dixon
On 12/07/2011 19:07, Doug Bradbury wrote: Does anyone have suggestions for an active and easy to use XML building parsing module? Hi Doug Any code to write XML ends up looking very similar to the resulting XML itself, although XML::Writer will make sure your syntax is correct for you and

Re: XML suggestions

2011-07-12 Thread Feng He
2011/7/13 Doug Bradbury dbradb...@8thlight.com: Does anyone have suggestions for an active and easy to use XML building parsing module? For a simple XML parsing I have used the module XML::Simple which just run well. Regards. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For

print output on console at runtime

2011-07-12 Thread Irfan Sayed
hi, i need to print the output of a command on the console at runtime lets say, i need to execute find command .as of now , what i am doing is , @cmd= `find . -name abc`; print @cmd\n; now what happens is, once the command completed then it will send entire output to @cmd and then entire